aboutsummaryrefslogtreecommitdiffhomepage
path: root/internal/workflows
diff options
context:
space:
mode:
authorOphestra <cat@gensokyo.uk>2026-10-17 17:30:15 +0900
committerOphestra <cat@gensokyo.uk>2026-10-17 18:01:12 +0900
commitd1a648f9379fe2b4f6a3b2230889d520cae2f868 (patch)
treea9d74fc44d7a4bb135af5b2acccdc8b14fb4bcd8 /internal/workflows
parent79cd9088c7b541d2a3c9e9cad879f0ae46632ca6 (diff)
cmd/hakurei/testsuite: migrate testsHEADmasterdevelop
This runs much faster than the NixOS test suite, and is much more precise. This also uncovered a recent severe pipewire regression. This change removes all remaining deprecated nix code. Closes #22. Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'internal/workflows')
-rw-r--r--internal/workflows/Containerfile3
-rw-r--r--internal/workflows/doc.go3
-rw-r--r--internal/workflows/step.go12
-rw-r--r--internal/workflows/test.go22
4 files changed, 18 insertions, 22 deletions
diff --git a/internal/workflows/Containerfile b/internal/workflows/Containerfile
index eb858831..82ce8820 100644
--- a/internal/workflows/Containerfile
+++ b/internal/workflows/Containerfile
@@ -8,13 +8,16 @@ RUN add-apt-repository -y ppa:savoury1/pipewire && \
acl \
sway \
xwayland \
+ x11-xserver-utils \
xdg-dbus-proxy \
+ libnotify-bin \
pipewire \
pipewire-pulse \
wireplumber- \
pulseaudio-utils \
foot \
xterm \
+ grim \
fuse3 \
fsmark && \
apt-get clean && rm -rf /var/lib/apt/lists/*
diff --git a/internal/workflows/doc.go b/internal/workflows/doc.go
index 123bf7c1..e220ed67 100644
--- a/internal/workflows/doc.go
+++ b/internal/workflows/doc.go
@@ -38,6 +38,9 @@ On Alpine Linux, this is achieved by:
# Use any other user for rootless mode.
podman_user="act_runner"
+ # Required by cmd/hakurei test suite.
+ rc_ulimit="-r 49"
+
A symlink must then be created at /var/run/docker.sock pointing to the socket
owned by the unprivileged daemon. This should be done in a /etc/local.d script.
diff --git a/internal/workflows/step.go b/internal/workflows/step.go
index 5175d4d5..3458c0ea 100644
--- a/internal/workflows/step.go
+++ b/internal/workflows/step.go
@@ -58,15 +58,3 @@ func newTestsuite(name, prefix string) Step {
Run: prefix + "go run -tags=testsuite ./cmd/" + name,
}
}
-
-// newNixOSTest returns a step for running the named NixOS test.
-func newNixOSTest(name string) Step {
- return Step{
- Name: "Run NixOS test",
- Run: "nix build " +
- "--out-link result " +
- "--print-out-paths " +
- "--print-build-logs " +
- "./cmd/hakurei/testsuite#checks.x86_64-linux." + name,
- }
-}
diff --git a/internal/workflows/test.go b/internal/workflows/test.go
index 5ca795c6..b0819916 100644
--- a/internal/workflows/test.go
+++ b/internal/workflows/test.go
@@ -7,25 +7,27 @@ var _ = (&Workflow{
On: []any{"push"},
Jobs: Map[Job]{
- {"hakurei-legacy", Job{
- Name: "Hakurei (legacy)",
- On: "nix",
+ {"hakurei", Job{
+ Name: "Hakurei",
+ On: "rosa",
Steps: []Step{
checkout,
- newNixOSTest("hakurei"),
- newUploadArtifact("test output", "hakurei-vm-output"),
+ dist,
+ install,
+ newTestsuite("hakurei/testsuite", "unshare -n "),
},
}},
- {"hakurei-race-legacy", Job{
- Name: "Hakurei (legacy with race instrument)",
- On: "nix",
+ {"hakurei-race", Job{
+ Name: "Hakurei (with race instrument)",
+ On: "rosa",
Steps: []Step{
checkout,
- newNixOSTest("race"),
- newUploadArtifact("test output", "hakurei-race-vm-output"),
+ _dist,
+ install,
+ newTestsuite("hakurei/testsuite", "unshare -n "),
},
}},