From: Rafael Zalamena Date: Thu, 22 Jun 2017 19:07:13 +0000 (-0300) Subject: ospf: add memory leak test X-Git-Tag: frr-7.1-dev~151^2~264 X-Git-Url: https://git.puffer.fish/?a=commitdiff_plain;h=622cc178c70342f348cf621022da0aa5432413ca;p=matthieu%2Ffrr.git ospf: add memory leak test Standard memory leak test/report. --- diff --git a/tests/topotests/ospf-topo1/test_ospf_topo1.py b/tests/topotests/ospf-topo1/test_ospf_topo1.py index 352e6dde66..884cb33e6b 100755 --- a/tests/topotests/ospf-topo1/test_ospf_topo1.py +++ b/tests/topotests/ospf-topo1/test_ospf_topo1.py @@ -154,6 +154,14 @@ def test_ospf_link_down(): count=20, wait=3) assert result, 'OSPF did not converge on {}:\n{}'.format(router, diff) +def test_memory_leak(): + "Run the memory leak test and report results." + tgen = get_topogen() + if not tgen.is_memleak_enabled(): + pytest.skip('Memory leak test/report is disabled') + + tgen.report_memory_leaks() + if __name__ == '__main__': args = ["-s"] + sys.argv[1:] sys.exit(pytest.main(args))