From 798fb5934d6f45b7ce69d18e4579b3f15012a3ad Mon Sep 17 00:00:00 2001 From: Martin Winter Date: Mon, 24 Apr 2017 16:12:55 -0700 Subject: [PATCH] all-protocol-startup: Fix bad assert in case of failed vtysh output test Signed-off-by: Martin Winter --- .../all-protocol-startup/test_all_protocol_startup.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) 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) -- 2.39.5