Skip to content

Commit cdfbf24

Browse files
authored
Merge pull request #183 from briancroom/reexport-foundation
Re-export Foundation from XCTest
2 parents 38961cd + 2e48a9b commit cdfbf24

28 files changed

+4
-124
lines changed

Sources/XCTest/Private/PerformanceMeter.swift

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,6 @@
1111
// Measures the performance of a block of code and reports the results.
1212
//
1313

14-
#if os(macOS)
15-
import SwiftFoundation
16-
#else
17-
import Foundation
18-
#endif
19-
2014
/// Describes a type that is capable of measuring some aspect of code performance
2115
/// over time.
2216
internal protocol PerformanceMetric {

Sources/XCTest/Private/PrintObserver.swift

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,6 @@
1111
// Prints test progress to stdout.
1212
//
1313

14-
#if os(macOS)
15-
import SwiftFoundation
16-
#else
17-
import Foundation
18-
#endif
19-
2014
/// Prints textual representations of each XCTestObservation event to stdout.
2115
/// Mirrors the Apple XCTest output exactly.
2216
internal class PrintObserver: XCTestObservation {

Sources/XCTest/Private/TestListing.swift

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,6 @@
1111
// Implementation of the mode for printing the list of tests.
1212
//
1313

14-
#if os(macOS)
15-
import SwiftFoundation
16-
#else
17-
import Foundation
18-
#endif
19-
2014
internal struct TestListing {
2115
private let testSuite: XCTestSuite
2216

Sources/XCTest/Private/WallClockTimeMetric.swift

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,6 @@
1111
// Performance metric measuring how long it takes code to execute
1212
//
1313

14-
#if os(macOS)
15-
import SwiftFoundation
16-
#else
17-
import Foundation
18-
#endif
19-
2014
/// This metric uses the system uptime to keep track of how much time passes
2115
/// between starting and stopping measuring.
2216
internal final class WallClockTimeMetric: PerformanceMetric {

Sources/XCTest/Private/XCPredicateExpectation.swift

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,6 @@
1111
// Expectations with a specified predicate and object to evaluate.
1212
//
1313

14-
#if os(macOS)
15-
import SwiftFoundation
16-
#else
17-
import Foundation
18-
#endif
19-
2014
internal class XCPredicateExpectation: XCTestExpectation {
2115
internal let predicate: NSPredicate
2216
internal let object: AnyObject

Sources/XCTest/Private/XCTestCaseSuite.swift

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,6 @@
1111
// A test suite associated with a particular test case class.
1212
//
1313

14-
#if os(macOS)
15-
import SwiftFoundation
16-
#else
17-
import Foundation
18-
#endif
19-
2014
/// A test suite which is associated with a particular test case class. It will
2115
/// call `setUp` and `tearDown` on the class itself before and after invoking
2216
/// all of the test cases making up the class.

Sources/XCTest/Public/Asynchronous/XCNotificationExpectationHandler.swift

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,6 @@
1212
// observed.
1313
//
1414

15-
#if os(macOS)
16-
import SwiftFoundation
17-
#else
18-
import Foundation
19-
#endif
20-
2115
/// A block to be invoked when a notification specified by the expectation is
2216
/// observed.
2317
///

Sources/XCTest/Public/Asynchronous/XCPredicateExpectationHandler.swift

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,6 @@
1212
// evaluated with a given object.
1313
//
1414

15-
#if os(macOS)
16-
import SwiftFoundation
17-
#else
18-
import Foundation
19-
#endif
20-
2115
/// A block to be invoked when evaluating the predicate against the object
2216
/// returns true. If the block is not provided the first successful evaluation
2317
/// will fulfill the expectation. If provided, the handler can override that

Sources/XCTest/Public/Asynchronous/XCTestCase+Asynchronous.swift

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,6 @@
1111
// Methods on XCTestCase for testing asynchronous operations
1212
//
1313

14-
#if os(macOS)
15-
import SwiftFoundation
16-
#else
17-
import Foundation
18-
#endif
19-
2014
public extension XCTestCase {
2115

2216
/// Creates and returns an expectation associated with the test case.

Sources/XCTest/Public/Asynchronous/XCTestCase+NotificationExpectation.swift

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,6 @@
1010
// XCTestCase+NotificationExpectation.swift
1111
//
1212

13-
#if os(macOS)
14-
import SwiftFoundation
15-
#else
16-
import Foundation
17-
#endif
18-
1913
public extension XCTestCase {
2014
/// Creates and returns an expectation for a notification.
2115
///

0 commit comments

Comments
 (0)