From: Michael Tremer Date: Wed, 30 Mar 2022 15:29:49 +0000 (+0000) Subject: tests: Break after exporting 1000 networks X-Git-Tag: 0.9.13~6 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=e42bcbe49f1ef6f9cd6e8aa89ef95a32b5f3ad09;p=location%2Flibloc.git tests: Break after exporting 1000 networks Otherwise this test runs for forever Signed-off-by: Michael Tremer --- diff --git a/tests/python/test-export.py b/tests/python/test-export.py index cef87b3..419b105 100755 --- a/tests/python/test-export.py +++ b/tests/python/test-export.py @@ -41,7 +41,11 @@ class Test(unittest.TestCase): """ Lists all networks but flattened """ - for network in self.db.networks_flattened: + for i, network in enumerate(self.db.networks_flattened): + # Break after the first 1000 iterations + if i >= 1000: + break + print(network)