File tree 1 file changed +4
-5
lines changed 1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -12,6 +12,8 @@ import (
12
12
)
13
13
14
14
func TestSymlinkRealpath (t * testing.T ) {
15
+ t .Parallel ()
16
+
15
17
tmp := t .TempDir ()
16
18
17
19
target := filepath .Join (tmp , "target" )
@@ -36,13 +38,10 @@ func TestSymlinkRealpath(t *testing.T) {
36
38
assert .NilError (t , err )
37
39
assert .Equal (t , string (gotContents ), expectedContents )
38
40
39
- targetFileNormalized := tspath .NormalizePath (targetFile )
40
- linkFileNormalized := tspath .NormalizePath (linkFile )
41
-
42
41
fs := FromOS ()
43
42
44
43
// Realpath both; some systems like macOS make TempDir itself a symlink.
45
- targetRealpath := fs .Realpath (targetFileNormalized )
46
- linkRealpath := fs .Realpath (linkFileNormalized )
44
+ targetRealpath := fs .Realpath (tspath . NormalizePath ( targetFile ) )
45
+ linkRealpath := fs .Realpath (tspath . NormalizePath ( linkFile ) )
47
46
assert .Equal (t , targetRealpath , linkRealpath )
48
47
}
You can’t perform that action at this time.
0 commit comments