minecraft: speedup test
This commit is contained in:
parent
376ea182cb
commit
a910a30c01
@ -88,12 +88,11 @@ testPkgs.testers.runNixOSTest {
|
||||
# Wait for minecraft service to be available
|
||||
machine.wait_for_unit("minecraft-server-main.service")
|
||||
|
||||
machine.sleep(60)
|
||||
|
||||
# Check that the service is active and not failed
|
||||
machine.succeed("systemctl is-active minecraft-server-main.service")
|
||||
|
||||
# Check for the Minecraft server startup completion message
|
||||
machine.succeed("grep -Eq '\\[[0-9]+:[0-9]+:[0-9]+\\] \\[Server thread/INFO\\]: Done \\([0-9]+\\.[0-9]+s\\)! For help, type \"help\"' /var/lib/minecraft/main/logs/latest.log")
|
||||
# Wait up to 60 seconds for the server to complete startup
|
||||
with machine.nested("Waiting for minecraft server startup completion"):
|
||||
machine.wait_until_succeeds(
|
||||
"grep -Eq '\\[[0-9]+:[0-9]+:[0-9]+\\] \\[Server thread/INFO\\]: Done \\([0-9]+\\.[0-9]+s\\)! For help, type \"help\"' /var/lib/minecraft/main/logs/latest.log",
|
||||
timeout=60
|
||||
)
|
||||
'';
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user