nix: go generate in src derivation
All checks were successful
Test / Sandbox (push) Successful in 40s
Test / Fortify (race detector) (push) Successful in 49s
Test / Fortify (push) Successful in 50s
Test / Create distribution (push) Successful in 24s
Test / Sandbox (race detector) (push) Successful in 45s
Test / Fpkg (push) Successful in 39s
Test / Flake checks (push) Successful in 1m12s
All checks were successful
Test / Sandbox (push) Successful in 40s
Test / Fortify (race detector) (push) Successful in 49s
Test / Fortify (push) Successful in 50s
Test / Create distribution (push) Successful in 24s
Test / Sandbox (race detector) (push) Successful in 45s
Test / Fpkg (push) Successful in 39s
Test / Flake checks (push) Successful in 1m12s
This saves the generated files in the nix store and exposes them for use by external tools. Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
12
test/test.py
12
test/test.py
@@ -80,9 +80,6 @@ def fortify(command):
|
||||
start_all()
|
||||
machine.wait_for_unit("multi-user.target")
|
||||
|
||||
# Run fortify Go tests outside of nix build in the background:
|
||||
machine.succeed("sudo -u untrusted -i fortify-go-test &> /tmp/go-test &")
|
||||
|
||||
# To check fortify's version:
|
||||
print(machine.succeed("sudo -u alice -i fortify version"))
|
||||
|
||||
@@ -90,6 +87,9 @@ print(machine.succeed("sudo -u alice -i fortify version"))
|
||||
machine.wait_for_file("/run/user/1000/wayland-1")
|
||||
machine.wait_for_file("/tmp/sway-ipc.sock")
|
||||
|
||||
# Run fortify Go tests outside of nix build in the background:
|
||||
swaymsg("exec fortify-test")
|
||||
|
||||
# Deny unmapped uid:
|
||||
denyOutput = machine.fail("sudo -u untrusted -i fortify run &>/dev/stdout")
|
||||
print(denyOutput)
|
||||
@@ -255,6 +255,6 @@ machine.wait_for_file("/tmp/sway-exit-ok")
|
||||
print(machine.succeed("find /run/user/1000/fortify"))
|
||||
|
||||
# Verify go test status:
|
||||
machine.wait_for_file("/tmp/go-test", timeout=5)
|
||||
print(machine.succeed("cat /tmp/go-test"))
|
||||
machine.wait_for_file("/tmp/go-test-ok", timeout=5)
|
||||
machine.wait_for_file("/tmp/fortify-test-done")
|
||||
print(machine.succeed("cat /tmp/fortify-test.log"))
|
||||
machine.wait_for_file("/tmp/fortify-test-ok", timeout=2)
|
||||
|
||||
Reference in New Issue
Block a user