Skip to content

Commit

Permalink
Fix symlinks not fully cleaned up in Node.js tests (#349)
Browse files Browse the repository at this point in the history
`FileSystem.isDirectory` returns `false` when running it on broken symlinks, which breaks Node.js tests flow. We should be able to clean up all symlinks, even broken ones. Other we can't create new correct symlinks because broken symlinks already exist at those paths.
  • Loading branch information
MaxDesiatov committed May 23, 2022
1 parent 8130899 commit b5680cb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Sources/CartonHelpers/FileSystem.swift
Expand Up @@ -52,7 +52,7 @@ public extension FileSystem {

func resourcesDirectoryNames(relativeTo buildDirectory: AbsolutePath) throws -> [String] {
try getDirectoryContents(buildDirectory).filter {
$0.hasSuffix(".resources") && isDirectory(buildDirectory.appending(component: $0))
$0.hasSuffix(".resources")
}
}
}

0 comments on commit b5680cb

Please sign in to comment.