aboutsummaryrefslogtreecommitdiffhomepage
path: root/system/mkdir_test.go
diff options
context:
space:
mode:
authorOphestra <cat@gensokyo.uk>2025-09-02 04:54:34 +0900
committerOphestra <cat@gensokyo.uk>2025-09-02 04:54:34 +0900
commit6f719bc3c19d56279d2d76d3bcf8fb66ace2d2fb (patch)
tree6e9e84fd6f382fa823c87a70a0df0284dc127250 /system/mkdir_test.go
parent1b5d20a39b2c5720d83a8eaf3d2227deb46a7c0d (diff)
system: update doc commands and remove mutex
The mutex is not really doing anything, none of these methods make sense when called concurrently anyway. The copylocks analysis is still satisfied by the noCopy struct. Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'system/mkdir_test.go')
-rw-r--r--system/mkdir_test.go10
1 files changed, 5 insertions, 5 deletions
diff --git a/system/mkdir_test.go b/system/mkdir_test.go
index 706b3d1f..8fc12a17 100644
--- a/system/mkdir_test.go
+++ b/system/mkdir_test.go
@@ -19,9 +19,9 @@ func TestEnsure(t *testing.T) {
}
for _, tc := range testCases {
t.Run(tc.name+"_"+tc.perm.String(), func(t *testing.T) {
- sys := New(150)
+ sys := New(t.Context(), 150)
sys.Ensure(tc.name, tc.perm)
- (&tcOp{User, tc.name}).test(t, sys.ops, []Op{&Mkdir{User, tc.name, tc.perm, false}}, "Ensure")
+ (&tcOp{User, tc.name}).test(t, sys.ops, []Op{&MkdirOp{User, tc.name, tc.perm, false}}, "Ensure")
})
}
}
@@ -36,9 +36,9 @@ func TestEphemeral(t *testing.T) {
}
for _, tc := range testCases {
t.Run(tc.path+"_"+tc.perm.String()+"_"+TypeString(tc.et), func(t *testing.T) {
- sys := New(150)
+ sys := New(t.Context(), 150)
sys.Ephemeral(tc.et, tc.path, tc.perm)
- tc.test(t, sys.ops, []Op{&Mkdir{tc.et, tc.path, tc.perm, true}}, "Ephemeral")
+ tc.test(t, sys.ops, []Op{&MkdirOp{tc.et, tc.path, tc.perm, true}}, "Ephemeral")
})
}
}
@@ -60,7 +60,7 @@ func TestMkdirString(t *testing.T) {
}
for _, tc := range testCases {
t.Run(tc.want, func(t *testing.T) {
- m := &Mkdir{
+ m := &MkdirOp{
et: tc.et,
path: container.Nonexistent,
perm: 0701,