Skip to content

Commit

Permalink
Replace normalized paths in TestUtils
Browse files Browse the repository at this point in the history
  • Loading branch information
vipentti committed Dec 27, 2023
1 parent 4c7f2ae commit 5913c47
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions tests/Visp.Compiler.UnitTests/TestUtils.fs
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,8 @@ let runWriteTest (name: string) =
let filePathToReplace =
Path.GetDirectoryName path |> Path.TrimEndingDirectorySeparator

let normalizedPathToReplace = Syntax.NormalizedPath(filePathToReplace).Path

try
let parsed = CoreParser.parseFile path ParserOptions.Default

Expand All @@ -97,6 +99,7 @@ let runWriteTest (name: string) =
let output =
stream
.ToString()
.Replace(normalizedPathToReplace + "/", "")
.Replace(filePathToReplace + "/", "")
.Replace(filePathToReplace + "\\", "")

Expand Down

0 comments on commit 5913c47

Please sign in to comment.