diff options
| author | Ophestra <cat@gensokyo.uk> | 2025-08-29 22:15:05 +0900 |
|---|---|---|
| committer | Ophestra <cat@gensokyo.uk> | 2025-08-29 22:15:05 +0900 |
| commit | 08eeafe8174efed2414d66788a927168efeba691 (patch) | |
| tree | 966ab2b3abec177ee3eaeac777b4b636a32261df /container/path_test.go | |
| parent | d7c7c69a13868546c26c3e5096fca09304a6e182 (diff) | |
container/mount: unwrap vfs decoder errors
These are now handled by init. This eliminates generic WrapErr from mount and procPaths.
Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'container/path_test.go')
| -rw-r--r-- | container/path_test.go | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/container/path_test.go b/container/path_test.go index 7184b0bf..746e70fe 100644 --- a/container/path_test.go +++ b/container/path_test.go @@ -1,7 +1,6 @@ package container import ( - "errors" "io" "math" "os" @@ -248,8 +247,8 @@ func TestProcPaths(t *testing.T) { t.Fatalf("WriteFile: error = %v", err) } - wantErr := wrapErrSuffix(&vfs.DecoderError{Op: "parse", Line: 0, Err: vfs.ErrMountInfoFields}, "cannot parse mountinfo:") - if err := newProcPaths(direct{}, tempDir).mountinfo(func(d *vfs.MountInfoDecoder) error { return d.Decode(new(*vfs.MountInfo)) }); !errors.Is(err, wantErr) { + wantErr := &vfs.DecoderError{Op: "parse", Line: 0, Err: vfs.ErrMountInfoFields} + if err := newProcPaths(direct{}, tempDir).mountinfo(func(d *vfs.MountInfoDecoder) error { return d.Decode(new(*vfs.MountInfo)) }); !reflect.DeepEqual(err, wantErr) { t.Fatalf("mountinfo: error = %v, want %v", err, wantErr) } }) |
