Skip to content

Commit

Permalink
test: add NoErr checks for os.Symlink calls
Browse files Browse the repository at this point in the history
  • Loading branch information
Felixoid committed Feb 9, 2022
1 parent ef73bef commit 0de20e8
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions glob_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -460,8 +460,10 @@ func TestGlob(t *testing.T) { // nolint:funlen
fsPath := testFS.Path()
workingSymlink := filepath.Join(fsPath, "b")
brokenSymlink := filepath.Join(fsPath, "c")
os.Symlink("a", workingSymlink)
os.Symlink("non-existent", brokenSymlink)
err := os.Symlink("a", workingSymlink)
require.NoError(t, err)
err = os.Symlink("non-existent", brokenSymlink)
require.NoError(t, err)

matches, err := Glob(workingSymlink)
require.NoError(t, err)
Expand Down

0 comments on commit 0de20e8

Please sign in to comment.