diff options
| author | Ophestra <cat@gensokyo.uk> | 2025-08-29 21:51:31 +0900 |
|---|---|---|
| committer | Ophestra <cat@gensokyo.uk> | 2025-08-29 21:51:31 +0900 |
| commit | 50972096cd8bffd9b17dbdf656ec34c48edb8f86 (patch) | |
| tree | 1ad00bbf65f59539aa9bd0b3e1f42b89b7ca3fcb /container/path_test.go | |
| parent | 905b9f9785263297611a61facc8b6bdf4c3e257f (diff) | |
container/vfs: wrap decoder errors
This passes line information and handles strconv errors so it reads better.
Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'container/path_test.go')
| -rw-r--r-- | container/path_test.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/container/path_test.go b/container/path_test.go index c3b68b3d..7184b0bf 100644 --- a/container/path_test.go +++ b/container/path_test.go @@ -248,7 +248,7 @@ func TestProcPaths(t *testing.T) { t.Fatalf("WriteFile: error = %v", err) } - wantErr := wrapErrSuffix(vfs.ErrMountInfoFields, "cannot parse mountinfo:") + 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) { t.Fatalf("mountinfo: error = %v, want %v", err, wantErr) } |
