Esempio n. 1
0
This matches the client environment used in make test
server is pid `cat \$PIDDIR/samba.pid`

Some useful environment variables:
TORTURE_OPTIONS=\$TORTURE_OPTIONS
SMB_CONF_PATH=\$SMB_CONF_PATH

$envvarstr
\" && LD_LIBRARY_PATH=%(LD_LIBRARY_PATH)s $(SHELL)'""" % {
        "testenv_name": testenv_name,
        "LD_LIBRARY_PATH": os.environ["LD_LIBRARY_PATH"]}
    subprocess.call(term + ' ' + cmd, shell=True)
    env_manager.teardown_env(testenv_name)
elif opts.list:
    for (name, envname, cmd, supports_loadfile, supports_idlist, subtests) in todo:
        cmd = expand_command_list(cmd)
        if cmd is None:
            warnings.warn("Unable to list tests in %s" % name)
            continue

        exitcode = subprocess.call(cmd, shell=True)

        if exitcode != 0:
            sys.stderr.write("%s exited with exit code %s\n" % (cmd, exitcode))
            sys.exit(1)
else:
    for (name, envname, cmd, supports_loadfile, supports_idlist, subtests) in todo:
        try:
            env = switch_env(envname, prefix)
        except UnsupportedEnvironment:
            subunit_ops.start_testsuite(name)
Esempio n. 2
0
 def test_list(self):
     self.assertEquals("test --list", expand_command_list("test $LISTOPT"))
Esempio n. 3
0
 def test_list(self):
     self.assertEquals("test --list", expand_command_list("test $LISTOPT"))
Esempio n. 4
0
 def test_no_list(self):
     self.assertIs(None, expand_command_list("test bla"))
Esempio n. 5
0
 def test_no_list(self):
     self.assertIs(None, expand_command_list("test bla"))