summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2011-11-07 15:24:01 +1100
committerAndrew Tridgell <tridge@samba.org>2011-11-10 14:24:21 +1100
commit46723aa2da81742995950ca3c6f403e081c5ba05 (patch)
tree3ad4aca77d05241303e3e82441bcf196ec31d0d5 /source4
parenta7c1add5c49e4c241bfe95ca018b75a2889a2141 (diff)
downloadsamba-46723aa2da81742995950ca3c6f403e081c5ba05.tar.gz
samba-46723aa2da81742995950ca3c6f403e081c5ba05.tar.bz2
samba-46723aa2da81742995950ca3c6f403e081c5ba05.zip
s4-test: improved error checking in samba-tool time test
Pair-Programmed-With: Amitay Isaacs <amitay@gmail.com>
Diffstat (limited to 'source4')
-rw-r--r--source4/scripting/python/samba/tests/samba_tool/timecmd.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/source4/scripting/python/samba/tests/samba_tool/timecmd.py b/source4/scripting/python/samba/tests/samba_tool/timecmd.py
index 8eb96ae874..b9946f8f56 100644
--- a/source4/scripting/python/samba/tests/samba_tool/timecmd.py
+++ b/source4/scripting/python/samba/tests/samba_tool/timecmd.py
@@ -40,4 +40,6 @@ class TimeCmdTestCase(SambaToolCmdTest):
def test_timefail(self):
"""Run time against a non-existant server, and make sure it fails"""
(result, out, err) = self.runcmd("time", "notaserver")
+ self.assertEquals(result, -1, "check for result code")
+ self.assertTrue(err.strip().endswith("NT_STATUS_OBJECT_NAME_NOT_FOUND"), "ensure right error string")
self.assertEquals(out, "", "ensure no output returned")