diff options
| author | Ophestra <cat@gensokyo.uk> | 2026-10-03 18:46:38 +0900 |
|---|---|---|
| committer | Ophestra <cat@gensokyo.uk> | 2026-10-03 18:52:11 +0900 |
| commit | f2e188c4a0f472bcbd87189f63099d2c73936789 (patch) | |
| tree | 1b96bd5bb8ae99460d93e6d477e5ee024a08b009 /test/internal/testsuite/testsuite_root.go | |
| parent | aa41002e8078a3ab00896cbd403e573c6dd817c2 (diff) | |
test/internal/testsuite: move ptrace helpers
This also cleans up their API.
Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'test/internal/testsuite/testsuite_root.go')
| -rw-r--r-- | test/internal/testsuite/testsuite_root.go | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/test/internal/testsuite/testsuite_root.go b/test/internal/testsuite/testsuite_root.go new file mode 100644 index 00000000..830e272c --- /dev/null +++ b/test/internal/testsuite/testsuite_root.go @@ -0,0 +1,14 @@ +//go:build testsuite + +package testsuite + +import ( + "log" + "os" +) + +func init() { + if os.Geteuid() != 0 { + log.Fatal("this program must run as root") + } +} |
