-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test: Fix restore_dir() unit restart race
firewalld writes its configuration files on shutdown. Previously, the test cleanup first restored the files and *then* restarted firewalld, which sometimes leaked changes from the test into the persistent config. That led to subsequent tests timing out to load the login page, as the `cockpit` service was missing in firewalld. This is a potential race condition for all service restarts, so fix it in a general way: Introduce a new `restart_unit` argument to `restore_dir()`, which first stops the unit, then restores the files, and then starts the unit again if it was running before. Convert all affected tests to the new API. Cherry-picked from main commit ce07ea7
- Loading branch information
1 parent
1b0f5ef
commit dd85c0f
Showing
6 changed files
with
31 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters