diff --git a/test/units/TEST-75-RESOLVED.sh b/test/units/TEST-75-RESOLVED.sh index fd07fd898a..25ab02a938 100755 --- a/test/units/TEST-75-RESOLVED.sh +++ b/test/units/TEST-75-RESOLVED.sh @@ -936,6 +936,15 @@ testcase_11_nft() { # Test resolvectl show-server-state testcase_12_resolvectl2() { + # Cleanup + # shellcheck disable=SC2317 + cleanup() { + rm -f /run/systemd/resolved.conf.d/reload.conf + systemctl reload systemd-resolved.service + } + + trap cleanup RETURN + run resolvectl show-server-state grep -qF "10.0.0.1" "$RUN_OUT" grep -qF "Interface" "$RUN_OUT"