summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorKamen Mazdrashki <kamenim@samba.org>2010-09-29 16:00:43 +0300
committerKamen Mazdrashki <kamenim@samba.org>2010-10-03 01:24:57 +0300
commit2a23f0d524298c2cc78f36a2f5b45560ec36747f (patch)
treeabf7f30fa14cc153def536654d9d2c6454b9cdc7 /source4
parentc05180caa78eac0beb26c6791afd8642a97853e6 (diff)
downloadsamba-2a23f0d524298c2cc78f36a2f5b45560ec36747f.tar.gz
samba-2a23f0d524298c2cc78f36a2f5b45560ec36747f.tar.bz2
samba-2a23f0d524298c2cc78f36a2f5b45560ec36747f.zip
s4-test-fsmo.py: Use common implementation for env_get_var_value()
Diffstat (limited to 'source4')
-rw-r--r--source4/torture/drs/python/fsmo.py10
1 files changed, 2 insertions, 8 deletions
diff --git a/source4/torture/drs/python/fsmo.py b/source4/torture/drs/python/fsmo.py
index bafff94024..eb1f3c2a66 100644
--- a/source4/torture/drs/python/fsmo.py
+++ b/source4/torture/drs/python/fsmo.py
@@ -53,10 +53,10 @@ class DrsFsmoTestCase(samba.tests.TestCase):
self.sleep_time = 5
# connect to DCs singleton
if self.ldb_dc1 is None:
- DrsFsmoTestCase.dc1 = get_env_var("DC1")
+ DrsFsmoTestCase.dc1 = samba.tests.env_get_var_value("DC1")
DrsFsmoTestCase.ldb_dc1 = samba.tests.connect_samdb(self.dc1, ldap_only=True)
if self.ldb_dc2 is None:
- DrsFsmoTestCase.dc2 = get_env_var("DC2")
+ DrsFsmoTestCase.dc2 = samba.tests.env_get_var_value("DC2")
DrsFsmoTestCase.ldb_dc2 = samba.tests.connect_samdb(self.dc2, ldap_only=True)
# fetch rootDSEs
@@ -152,9 +152,3 @@ class DrsFsmoTestCase(samba.tests.TestCase):
self._role_transfer(role="naming", role_dn=self.naming_dn)
pass
-
-########################################################################################
-def get_env_var(var_name):
- if not var_name in os.environ.keys():
- raise AssertionError("Please supply %s in environment" % var_name)
- return os.environ[var_name]