diff options
| author | Ophestra <cat@gensokyo.uk> | 2025-08-31 23:11:25 +0900 |
|---|---|---|
| committer | Ophestra <cat@gensokyo.uk> | 2025-08-31 23:11:25 +0900 |
| commit | 49600a6f46d99ff35d883381670548de1f01846e (patch) | |
| tree | 9c4a8067f2155eca36a29c6bb99f82ecb81c2495 /container/initmkdir_test.go | |
| parent | b489a3bba15bc6d808d7cc9c17f74dd833d32b9e (diff) | |
container/stub: export stub helpers
These are very useful in many packages containing relatively large amount of code making calls to difficult or impossible to stub functions.
Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'container/initmkdir_test.go')
| -rw-r--r-- | container/initmkdir_test.go | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/container/initmkdir_test.go b/container/initmkdir_test.go index 1f54e748..1a8a8f15 100644 --- a/container/initmkdir_test.go +++ b/container/initmkdir_test.go @@ -3,6 +3,8 @@ package container import ( "os" "testing" + + "hakurei.app/container/stub" ) func TestMkdirOp(t *testing.T) { @@ -10,8 +12,8 @@ func TestMkdirOp(t *testing.T) { {"success", new(Params), &MkdirOp{ Path: MustAbs("/.hakurei"), Perm: 0500, - }, nil, nil, []kexpect{ - {"mkdirAll", expectArgs{"/sysroot/.hakurei", os.FileMode(0500)}, nil, nil}, + }, nil, nil, []stub.Call{ + {"mkdirAll", stub.ExpectArgs{"/sysroot/.hakurei", os.FileMode(0500)}, nil, nil}, }, nil}, }) |
