lib/fs: Use io/fs errors as recommended in std lib (#8726)

This commit is contained in:
Simon Frei
2022-12-21 23:42:22 +01:00
committed by GitHub
parent 09f4d865ae
commit 634a3d0e3b
2 changed files with 15 additions and 9 deletions
+2 -2
View File
@@ -996,8 +996,8 @@ func TestIssue4901(t *testing.T) {
if err == nil {
t.Fatal("expected an error")
}
if fs.IsNotExist(err) {
t.Fatal("unexpected error type")
if err == fs.ErrNotExist {
t.Fatalf("unexpected error type: %T", err)
}
if !IsParseError(err) {
t.Fatal("failure to load included file should be a parse error")