11/*
22 This source file is part of the Swift.org open source project
33
4- Copyright (c) 2014 - 2017 Apple Inc. and the Swift project authors
4+ Copyright (c) 2014 - 2020 Apple Inc. and the Swift project authors
55 Licensed under Apache License v2.0 with Runtime Library Exception
66
77 See http://swift.org/LICENSE.txt for license information
@@ -12,7 +12,7 @@ import XCTest
1212import TSCBasic
1313import TSCTestSupport
1414
15- import TSCUtility
15+ @ testable import TSCUtility
1616
1717final class PkgConfigParserTests : XCTestCase {
1818
@@ -91,6 +91,9 @@ final class PkgConfigParserTests: XCTestCase {
9191
9292 /// Test custom search path get higher priority for locating pc files.
9393 func testCustomPcFileSearchPath( ) throws {
94+ /// Temporary workaround for PCFileFinder's use of static variables.
95+ PCFileFinder . resetCachedPkgConfigPaths ( )
96+
9497 let diagnostics = DiagnosticsEngine ( )
9598
9699 let fs = InMemoryFileSystem ( emptyFiles:
@@ -109,6 +112,9 @@ final class PkgConfigParserTests: XCTestCase {
109112 }
110113
111114 func testBrewPrefix( ) throws {
115+ /// Temporary workaround for PCFileFinder's use of static variables.
116+ PCFileFinder . resetCachedPkgConfigPaths ( )
117+
112118 try testWithTemporaryDirectory { tmpdir in
113119 let fakePkgConfig = tmpdir. appending ( components: " bin " , " pkg-config " )
114120 try localFileSystem. createDirectory ( fakePkgConfig. parentDirectory)
0 commit comments