launcher: make the shadowed-hostname preflight test machine-independent
The new hook-config check warns when the deployed openfut.cfg disagrees with the configured server, and this test counts warnings across every check. On the game machine — which by definition has a hook deployed — that second warning broke the assertion. Caught by running the suite on .105 rather than only on the server host. Pins the game dir for the same reason the tools dir is pinned.
This commit is contained in:
+5
-1
@@ -408,9 +408,13 @@ mod tests {
|
||||
c.openfut_server_host = "127.0.0.2".into();
|
||||
c.ea_hostnames = vec!["localhost".into()];
|
||||
c.fifa17_tools_dir = "/nonexistent/openfut-tools".into();
|
||||
// Machine-independence: this counts warnings across every check, so the
|
||||
// game dir must not be a real one. A box with a hook deployed (the game
|
||||
// machine always has one) would otherwise add a drift warning here.
|
||||
c.fifa_game_dir = "/nonexistent/fifa-game-dir".into();
|
||||
let checks = run(&c);
|
||||
assert_eq!(failures(&checks), 0, "must not be reported as fatal");
|
||||
assert_eq!(warnings(&checks), 1);
|
||||
assert_eq!(warnings(&checks), 1, "{checks:#?}");
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
||||
Reference in New Issue
Block a user