From c93f9e18359f37d66cfa803811e5f4d7e752e8bc Mon Sep 17 00:00:00 2001 From: Guillaume Mulocher Date: Wed, 30 Oct 2024 17:05:53 +0100 Subject: [PATCH] Update anta/runner.py --- anta/runner.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/anta/runner.py b/anta/runner.py index 947757aff..7b0eadf75 100644 --- a/anta/runner.py +++ b/anta/runner.py @@ -152,8 +152,7 @@ def prepare_tests( for device in inventory.devices: if tags: # If there are CLI tags, execute tests with matching tags for this device - matching_tags = tags.intersection(device.tags) - if not matching_tags: + if not (matching_tags := tags.intersection(device.tags)): # The device does not have any selected tag, skipping continue device_to_tests[device].update(catalog.get_tests_by_tags(matching_tags))