From 72c64c11e5b77901606a3f732aefcfa64f5d14d7 Mon Sep 17 00:00:00 2001 From: kali Date: Mon, 27 Aug 2012 05:20:44 +0900 Subject: fix expanduser for home in expected openvpn option --- src/leap/eip/tests/test_config.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/leap/eip/tests/test_config.py b/src/leap/eip/tests/test_config.py index 3c5a1cde..b6b06346 100644 --- a/src/leap/eip/tests/test_config.py +++ b/src/leap/eip/tests/test_config.py @@ -1,7 +1,6 @@ import ConfigParser import os import platform -import socket try: import unittest2 as unittest @@ -9,7 +8,6 @@ except ImportError: import unittest from leap.testing.basetest import BaseLeapTest -from leap.base import config as base_config from leap.eip import config as eip_config _system = platform.system() @@ -63,9 +61,8 @@ class EIPConfigTest(BaseLeapTest): args.append('/tmp/.eip.sock') args.append('unix') args.append('--config') - #XXX bad assumption. FIXME: expand $HOME - args.append('/home/%s/.config/leap/providers/default/openvpn.conf' % - username) + args.append(os.path.expanduser( + '~/.config/leap/providers/default/openvpn.conf')) return args # build command string -- cgit v1.2.3