aboutsummaryrefslogtreecommitdiffhomepage
path: root/test/sandbox/assert.go
diff options
context:
space:
mode:
authorOphestra <cat@gensokyo.uk>2025-03-27 03:09:16 +0900
committerOphestra <cat@gensokyo.uk>2025-03-27 03:11:50 +0900
commit996b42634dba83a488d0ac67eac954c0b5582c71 (patch)
tree04eb4b05bc6929b1cffb39b5aac345a5423efb86 /test/sandbox/assert.go
parent300571af4777c8322bc0c7fafdf18a5879c237e6 (diff)
test/sandbox: invoke check program directly
Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'test/sandbox/assert.go')
-rw-r--r--test/sandbox/assert.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/test/sandbox/assert.go b/test/sandbox/assert.go
index 43cdd9d4..3cf81ffb 100644
--- a/test/sandbox/assert.go
+++ b/test/sandbox/assert.go
@@ -34,10 +34,13 @@ type T struct {
MountsPath string
}
-func (t *T) MustCheckFile(wantFilePath string) {
+func (t *T) MustCheckFile(wantFilePath, markerPath string) {
var want *TestCase
mustDecode(wantFilePath, &want)
t.MustCheck(want)
+ if _, err := os.Create(markerPath); err != nil {
+ fatalf("cannot create success marker: %v", err)
+ }
}
func (t *T) MustCheck(want *TestCase) {