From b5630f6883c874d458d9ae3c666cfb7ae5e3121d Mon Sep 17 00:00:00 2001 From: Ophestra Date: Wed, 12 Nov 2025 23:03:22 +0900 Subject: [PATCH] test: move package sandbox internal This should never be used outside vm tests. Signed-off-by: Ophestra --- test/{ => internal}/sandbox/assert.go | 0 test/{ => internal}/sandbox/assert_test.go | 0 test/{ => internal}/sandbox/fs.go | 0 test/{ => internal}/sandbox/fs_test.go | 2 +- test/{ => internal}/sandbox/mount.go | 0 test/{ => internal}/sandbox/mount_test.go | 2 +- test/{ => internal}/sandbox/ptrace.go | 0 test/{ => internal}/sandbox/seccomp.go | 0 test/sandbox/tool/main.go | 2 +- test/sandbox/tool/package.nix | 4 ++-- 10 files changed, 5 insertions(+), 5 deletions(-) rename test/{ => internal}/sandbox/assert.go (100%) rename test/{ => internal}/sandbox/assert_test.go (100%) rename test/{ => internal}/sandbox/fs.go (100%) rename test/{ => internal}/sandbox/fs_test.go (98%) rename test/{ => internal}/sandbox/mount.go (100%) rename test/{ => internal}/sandbox/mount_test.go (99%) rename test/{ => internal}/sandbox/ptrace.go (100%) rename test/{ => internal}/sandbox/seccomp.go (100%) diff --git a/test/sandbox/assert.go b/test/internal/sandbox/assert.go similarity index 100% rename from test/sandbox/assert.go rename to test/internal/sandbox/assert.go diff --git a/test/sandbox/assert_test.go b/test/internal/sandbox/assert_test.go similarity index 100% rename from test/sandbox/assert_test.go rename to test/internal/sandbox/assert_test.go diff --git a/test/sandbox/fs.go b/test/internal/sandbox/fs.go similarity index 100% rename from test/sandbox/fs.go rename to test/internal/sandbox/fs.go diff --git a/test/sandbox/fs_test.go b/test/internal/sandbox/fs_test.go similarity index 98% rename from test/sandbox/fs_test.go rename to test/internal/sandbox/fs_test.go index 8dd920b..a7813ee 100644 --- a/test/sandbox/fs_test.go +++ b/test/internal/sandbox/fs_test.go @@ -10,7 +10,7 @@ import ( "testing" "testing/fstest" - "hakurei.app/test/sandbox" + "hakurei.app/test/internal/sandbox" ) var ( diff --git a/test/sandbox/mount.go b/test/internal/sandbox/mount.go similarity index 100% rename from test/sandbox/mount.go rename to test/internal/sandbox/mount.go diff --git a/test/sandbox/mount_test.go b/test/internal/sandbox/mount_test.go similarity index 99% rename from test/sandbox/mount_test.go rename to test/internal/sandbox/mount_test.go index 7d6b0df..65bcec4 100644 --- a/test/sandbox/mount_test.go +++ b/test/internal/sandbox/mount_test.go @@ -7,7 +7,7 @@ import ( "path" "testing" - "hakurei.app/test/sandbox" + "hakurei.app/test/internal/sandbox" ) func TestMountinfo(t *testing.T) { diff --git a/test/sandbox/ptrace.go b/test/internal/sandbox/ptrace.go similarity index 100% rename from test/sandbox/ptrace.go rename to test/internal/sandbox/ptrace.go diff --git a/test/sandbox/seccomp.go b/test/internal/sandbox/seccomp.go similarity index 100% rename from test/sandbox/seccomp.go rename to test/internal/sandbox/seccomp.go diff --git a/test/sandbox/tool/main.go b/test/sandbox/tool/main.go index ef3325d..889142d 100644 --- a/test/sandbox/tool/main.go +++ b/test/sandbox/tool/main.go @@ -12,7 +12,7 @@ import ( "strings" "syscall" - "hakurei.app/test/sandbox" + "hakurei.app/test/internal/sandbox" ) var ( diff --git a/test/sandbox/tool/package.nix b/test/sandbox/tool/package.nix index 92829b2..13e1827 100644 --- a/test/sandbox/tool/package.nix +++ b/test/sandbox/tool/package.nix @@ -12,7 +12,7 @@ buildGoModule rec { src = builtins.path { name = "${pname}-src"; - path = lib.cleanSource ../.; + path = lib.cleanSource ../../.; filter = path: type: (type == "directory") || (type == "regular" && lib.hasSuffix ".go" path); }; vendorHash = null; @@ -23,7 +23,7 @@ buildGoModule rec { nativeBuildInputs = [ pkg-config ]; preBuild = '' - go mod init hakurei.app/test/sandbox >& /dev/null + go mod init hakurei.app/test >& /dev/null ''; postInstall = ''