1
0
mirror of https://github.com/samba-team/samba.git synced 2025-08-04 08:22:08 +03:00

tests:samba_tool: pass stdout and stderr to assertCmdSuccess()

This allows us to generate better assert messages and give the
developer some ideas why the command wasn't able to run.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=12108

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
This commit is contained in:
Stefan Metzmacher
2016-08-02 12:33:34 +02:00
committed by Michael Adam
parent 9c6a4ea278
commit fed029a624
12 changed files with 60 additions and 61 deletions

View File

@ -44,7 +44,7 @@ class SitesCmdTestCase(BaseSitesCmdTestCase):
result, out, err = self.runsubcmd("sites", "create", sitename,
"-H", self.dburl, self.creds_string)
self.assertCmdSuccess(result)
self.assertCmdSuccess(result, out, err)
dnsites = ldb.Dn(self.samdb, "CN=Sites,%s" % self.config_dn)
dnsite = ldb.Dn(self.samdb, "CN=%s,%s" % (sitename, dnsites))
@ -89,7 +89,7 @@ class SitesSubnetCmdTestCase(BaseSitesCmdTestCase):
cidr, sitename,
"-H", self.dburl,
self.creds_string)
self.assertCmdSuccess(result)
self.assertCmdSuccess(result, out, err)
ret = self.samdb.search(base=self.config_dn,
scope=ldb.SCOPE_SUBTREE,