It isn't intuitive (to me) that a test just converting xml text into iptables commands should need to call dbus, so rather than forcing the next person to look through the commit logs and/or run the test under gdb to understand why this is needed, just add a short comment in the source. Signed-off-by: Laine Stump <laine@xxxxxxxxxx> --- tests/networkxml2firewalltest.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tests/networkxml2firewalltest.c b/tests/networkxml2firewalltest.c index e4f86bc3fc..68a82e60d6 100644 --- a/tests/networkxml2firewalltest.c +++ b/tests/networkxml2firewalltest.c @@ -187,6 +187,12 @@ mymain(void) return ret == 0 ? EXIT_SUCCESS : EXIT_FAILURE; } +/* NB: virgdbus must be mocked because this test calls + * networkAddFirewallRules(), which will always call + * virFirewallDIsRegistered(), which calls + * virGDBusIsServiceRegistered(). + */ + VIR_TEST_MAIN_PRELOAD(mymain, VIR_TEST_MOCK("virgdbus"), VIR_TEST_MOCK("virfirewall")) -- 2.33.1