From: Martin Winter Date: Mon, 24 Apr 2017 23:12:55 +0000 (-0700) Subject: all-protocol-startup: Fix bad assert in case of failed vtysh output test X-Git-Tag: frr-7.1-dev~151^2~335 X-Git-Url: https://git.puffer.fish/?a=commitdiff_plain;h=798fb5934d6f45b7ce69d18e4579b3f15012a3ad;p=mirror%2Ffrr.git all-protocol-startup: Fix bad assert in case of failed vtysh output test Signed-off-by: Martin Winter --- diff --git a/tests/topotests/all-protocol-startup/test_all_protocol_startup.py b/tests/topotests/all-protocol-startup/test_all_protocol_startup.py index ad0e6d2032..ca6cac4b61 100755 --- a/tests/topotests/all-protocol-startup/test_all_protocol_startup.py +++ b/tests/topotests/all-protocol-startup/test_all_protocol_startup.py @@ -181,10 +181,11 @@ def test_error_messages_vtysh(): if (vtystdout != ''): sys.stderr.write('\nr%s created some spurious VTYSH start StdOut messages:\n%s\n' % (i, vtystdout)) - failures += 1 else: print("r%s StdOut ok" % i) + assert vtystdout == '', "Vtysh StdOut Output check failed for router r%s:\n%s" % (i, vtystdout) + # # Second checking Standard Error # @@ -199,11 +200,10 @@ def test_error_messages_vtysh(): if (vtystderr != ''): sys.stderr.write('\nr%s created some spurious VTYSH start StdErr messages:\n<%s>\n' % (i, vtystderr)) - failures += 1 else: print("r%s StdErr ok" % i) - assert failures == 0, "IP RIP status failed for router r%s:\n%s" % (i, diff) + assert vtystderr == '', "Vtysh StdErr Output check failed for router r%s:\n%s" % (i, vtystderr) # For debugging after starting FRR/Quagga daemons, uncomment the next line # CLI(net)