File tree Expand file tree Collapse file tree 2 files changed +13
-14
lines changed
Tests/PackageGraphPerformanceTests Expand file tree Collapse file tree 2 files changed +13
-14
lines changed Original file line number Diff line number Diff line change @@ -190,7 +190,7 @@ public extension MockPackageContainer {
190
190
}
191
191
}
192
192
193
- public struct MockPackagesProvider : PackageContainerProvider {
193
+ public struct MockPackageContainerProvider : PackageContainerProvider {
194
194
public let containers : [ MockPackageContainer ]
195
195
public let containersByIdentifier : [ PackageReference : MockPackageContainer ]
196
196
Original file line number Diff line number Diff line change 6
6
7
7
See http://swift.org/LICENSE.txt for license information
8
8
See http://swift.org/CONTRIBUTORS.txt for Swift project authors
9
- */
9
+ */
10
10
11
11
import XCTest
12
12
13
- import TSCBasic
14
- import PackageModel
15
13
import PackageGraph
16
14
import PackageLoading
15
+ import PackageModel
17
16
import SourceControl
17
+ import TSCBasic
18
18
19
19
import struct TSCUtility. Version
20
20
@@ -24,34 +24,33 @@ private let v1: Version = "1.0.0"
24
24
private let v1Range : VersionSetSpecifier = . range( " 1.0.0 " ..< " 2.0.0 " )
25
25
26
26
class DependencyResolverRealWorldPerfTests : XCTestCasePerf {
27
-
28
27
func testKituraPubGrub_X100( ) throws {
29
- #if os(macOS)
28
+ #if os(macOS)
30
29
try runPackageTestPubGrub ( name: " kitura.json " , N: 100 )
31
- #endif
30
+ #endif
32
31
}
33
32
34
33
func testZewoPubGrub_X100( ) throws {
35
- #if os(macOS)
34
+ #if os(macOS)
36
35
try runPackageTestPubGrub ( name: " ZewoHTTPServer.json " , N: 100 )
37
- #endif
36
+ #endif
38
37
}
39
38
40
39
func testPerfectPubGrub_X100( ) throws {
41
- #if os(macOS)
40
+ #if os(macOS)
42
41
try runPackageTestPubGrub ( name: " PerfectHTTPServer.json " , N: 100 )
43
- #endif
42
+ #endif
44
43
}
45
44
46
45
func testSourceKittenPubGrub_X100( ) throws {
47
- #if os(macOS)
46
+ #if os(macOS)
48
47
try runPackageTestPubGrub ( name: " SourceKitten.json " , N: 100 )
49
- #endif
48
+ #endif
50
49
}
51
50
52
51
func runPackageTestPubGrub( name: String , N: Int = 1 ) throws {
53
52
let graph = try mockGraph ( for: name)
54
- let provider = MockPackagesProvider ( containers: graph. containers)
53
+ let provider = MockPackageContainerProvider ( containers: graph. containers)
55
54
56
55
measure {
57
56
for _ in 0 ..< N {
You can’t perform that action at this time.
0 commit comments