Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions Foundation.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -344,6 +344,7 @@
B9974B9A1EDF4A22007F15B8 /* HTTPMessage.swift in Sources */ = {isa = PBXBuildFile; fileRef = B9974B931EDF4A22007F15B8 /* HTTPMessage.swift */; };
B9974B9B1EDF4A22007F15B8 /* BodySource.swift in Sources */ = {isa = PBXBuildFile; fileRef = B9974B941EDF4A22007F15B8 /* BodySource.swift */; };
B9974B9C1EDF4A22007F15B8 /* EasyHandle.swift in Sources */ = {isa = PBXBuildFile; fileRef = B9974B951EDF4A22007F15B8 /* EasyHandle.swift */; };
BB3D7558208A1E500085CFDC /* TestImports.swift in Sources */ = {isa = PBXBuildFile; fileRef = BB3D7557208A1E500085CFDC /* TestImports.swift */; };
BD8042161E09857800487EB8 /* TestLengthFormatter.swift in Sources */ = {isa = PBXBuildFile; fileRef = BD8042151E09857800487EB8 /* TestLengthFormatter.swift */; };
BDBB65901E256BFA001A7286 /* TestEnergyFormatter.swift in Sources */ = {isa = PBXBuildFile; fileRef = BDBB658F1E256BFA001A7286 /* TestEnergyFormatter.swift */; };
BDFDF0A71DFF5B3E00C04CC5 /* TestPersonNameComponents.swift in Sources */ = {isa = PBXBuildFile; fileRef = BDFDF0A61DFF5B3E00C04CC5 /* TestPersonNameComponents.swift */; };
Expand Down Expand Up @@ -825,6 +826,7 @@
B9974B931EDF4A22007F15B8 /* HTTPMessage.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = HTTPMessage.swift; path = http/HTTPMessage.swift; sourceTree = "<group>"; };
B9974B941EDF4A22007F15B8 /* BodySource.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = BodySource.swift; sourceTree = "<group>"; };
B9974B951EDF4A22007F15B8 /* EasyHandle.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = EasyHandle.swift; sourceTree = "<group>"; };
BB3D7557208A1E500085CFDC /* TestImports.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TestImports.swift; sourceTree = "<group>"; };
BD8042151E09857800487EB8 /* TestLengthFormatter.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TestLengthFormatter.swift; sourceTree = "<group>"; };
BDBB658F1E256BFA001A7286 /* TestEnergyFormatter.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TestEnergyFormatter.swift; sourceTree = "<group>"; };
BDFDF0A61DFF5B3E00C04CC5 /* TestPersonNameComponents.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TestPersonNameComponents.swift; sourceTree = "<group>"; };
Expand Down Expand Up @@ -1431,6 +1433,7 @@
children = (
1520469A1D8AEABE00D02E36 /* HTTPServer.swift */,
EA66F6381BF1619600136161 /* main.swift */,
BB3D7557208A1E500085CFDC /* TestImports.swift */,
9F4ADBCF1ECD4F56001F0B3D /* xdgTestHelper */,
EA66F65A1BF1976100136161 /* Tests */,
EA66F6391BF1619600136161 /* Resources */,
Expand Down Expand Up @@ -2442,6 +2445,7 @@
90E645DF1E4C89A400D0D47C /* TestNSCache.swift in Sources */,
5B13B34A1C582D4C00651CE2 /* TestURL.swift in Sources */,
EA54A6FB1DB16D53009E0809 /* TestObjCRuntime.swift in Sources */,
BB3D7558208A1E500085CFDC /* TestImports.swift in Sources */,
5B13B34D1C582D4C00651CE2 /* TestNSUUID.swift in Sources */,
5B13B3281C582D4C00651CE2 /* TestBundle.swift in Sources */,
5B13B32A1C582D4C00651CE2 /* TestCharacterSet.swift in Sources */,
Expand Down
12 changes: 2 additions & 10 deletions TestFoundation/HTTPServer.swift
Original file line number Diff line number Diff line change
Expand Up @@ -14,17 +14,9 @@

import Dispatch

#if DEPLOYMENT_RUNTIME_OBJC || os(Linux)
import Foundation
import XCTest
#else
import SwiftFoundation
import SwiftXCTest
#endif

#if os(macOS) || os(iOS)
#if canImport(Darwin)
import Darwin
#elseif os(Linux)
#elseif canImport(Glibc)
import Glibc
#endif

Expand Down
11 changes: 0 additions & 11 deletions TestFoundation/TestAffineTransform.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,6 @@
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//



#if DEPLOYMENT_RUNTIME_OBJC || os(Linux)
import Foundation
import XCTest
#else
import SwiftFoundation
import SwiftXCTest
#endif


class TestAffineTransform : XCTestCase {
private let accuracyThreshold = 0.001

Expand Down
9 changes: 0 additions & 9 deletions TestFoundation/TestBundle.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,6 @@
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//


#if DEPLOYMENT_RUNTIME_OBJC || os(Linux)
import Foundation
import XCTest
#else
import SwiftFoundation
import SwiftXCTest
#endif

import CoreFoundation

internal func testBundle() -> Bundle {
Expand Down
12 changes: 0 additions & 12 deletions TestFoundation/TestByteCountFormatter.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,6 @@
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//



#if DEPLOYMENT_RUNTIME_OBJC || os(Linux)
import Foundation
import XCTest
#else
import SwiftFoundation
import SwiftXCTest
#endif



class TestByteCountFormatter : XCTestCase {

static var allTests: [(String, (TestByteCountFormatter) -> () throws -> Void)] {
Expand Down
8 changes: 0 additions & 8 deletions TestFoundation/TestCalendar.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,6 @@
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//

#if DEPLOYMENT_RUNTIME_OBJC || os(Linux)
import Foundation
import XCTest
#else
import SwiftFoundation
import SwiftXCTest
#endif

class TestCalendar: XCTestCase {

static var allTests: [(String, (TestCalendar) -> () throws -> Void)] {
Expand Down
8 changes: 0 additions & 8 deletions TestFoundation/TestCharacterSet.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,6 @@
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//

#if DEPLOYMENT_RUNTIME_OBJC || os(Linux)
import Foundation
import XCTest
#else
import SwiftFoundation
import SwiftXCTest
#endif

private struct Box: Equatable {
private let ns: NSCharacterSet
private let swift: CharacterSet
Expand Down
8 changes: 0 additions & 8 deletions TestFoundation/TestCodable.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,6 @@
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//

#if DEPLOYMENT_RUNTIME_OBJC || os(Linux)
import Foundation
import XCTest
#else
import SwiftFoundation
import SwiftXCTest
#endif

// MARK: - Helper Functions

private func makePersonNameComponents(namePrefix: String? = nil,
Expand Down
12 changes: 0 additions & 12 deletions TestFoundation/TestDate.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,6 @@
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//



#if DEPLOYMENT_RUNTIME_OBJC || os(Linux)
import Foundation
import XCTest
#else
import SwiftFoundation
import SwiftXCTest
#endif



class TestDate : XCTestCase {

static var allTests: [(String, (TestDate) -> () throws -> Void)] {
Expand Down
8 changes: 0 additions & 8 deletions TestFoundation/TestDateFormatter.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,6 @@
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//

#if DEPLOYMENT_RUNTIME_OBJC || os(Linux)
import Foundation
import XCTest
#else
import SwiftFoundation
import SwiftXCTest
#endif

class TestDateFormatter: XCTestCase {

let DEFAULT_LOCALE = "en_US"
Expand Down
8 changes: 0 additions & 8 deletions TestFoundation/TestDecimal.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,6 @@
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//

#if DEPLOYMENT_RUNTIME_OBJC || os(Linux)
import Foundation
import XCTest
#else
import SwiftFoundation
import SwiftXCTest
#endif

class TestDecimal: XCTestCase {

static var allTests : [(String, (TestDecimal) -> () throws -> Void)] {
Expand Down
8 changes: 0 additions & 8 deletions TestFoundation/TestEnergyFormatter.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,6 @@
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//

#if DEPLOYMENT_RUNTIME_OBJC || os(Linux)
import Foundation
import XCTest
#else
import SwiftFoundation
import SwiftXCTest
#endif

class TestEnergyFormatter: XCTestCase {
let formatter: EnergyFormatter = EnergyFormatter()

Expand Down
8 changes: 0 additions & 8 deletions TestFoundation/TestFileHandle.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,6 @@
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//

#if DEPLOYMENT_RUNTIME_OBJC || os(Linux)
import Foundation
import XCTest
#else
import SwiftFoundation
import SwiftXCTest
#endif

class TestFileHandle : XCTestCase {
static var allTests : [(String, (TestFileHandle) -> () throws -> ())] {
return [
Expand Down
8 changes: 0 additions & 8 deletions TestFoundation/TestFileManager.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,6 @@
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//

#if DEPLOYMENT_RUNTIME_OBJC || os(Linux)
import Foundation
import XCTest
#else
import SwiftFoundation
import SwiftXCTest
#endif

class TestFileManager : XCTestCase {

static var allTests: [(String, (TestFileManager) -> () throws -> Void)] {
Expand Down
8 changes: 0 additions & 8 deletions TestFoundation/TestHTTPCookie.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,6 @@
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//

#if DEPLOYMENT_RUNTIME_OBJC || os(Linux)
import Foundation
import XCTest
#else
import SwiftFoundation
import SwiftXCTest
#endif

class TestHTTPCookie: XCTestCase {

static var allTests: [(String, (TestHTTPCookie) -> () throws -> Void)] {
Expand Down
7 changes: 0 additions & 7 deletions TestFoundation/TestHTTPCookieStorage.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,6 @@
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//

#if DEPLOYMENT_RUNTIME_OBJC || os(Linux)
import Foundation
import XCTest
#else
import SwiftFoundation
import SwiftXCTest
#endif
import Dispatch

class TestHTTPCookieStorage: XCTestCase {
Expand Down
10 changes: 0 additions & 10 deletions TestFoundation/TestHost.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,6 @@
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//


#if DEPLOYMENT_RUNTIME_OBJC || os(Linux)
import Foundation
import XCTest
#else
import SwiftFoundation
import SwiftXCTest
#endif


class TestHost: XCTestCase {

static var allTests: [(String, (TestHost) -> () throws -> Void)] {
Expand Down
10 changes: 0 additions & 10 deletions TestFoundation/TestISO8601DateFormatter.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,6 @@
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//



#if DEPLOYMENT_RUNTIME_OBJC || os(Linux)
import Foundation
import XCTest
#else
import SwiftFoundation
import SwiftXCTest
#endif

class TestISO8601DateFormatter: XCTestCase {

static var allTests : [(String, (TestISO8601DateFormatter) -> () throws -> Void)] {
Expand Down
18 changes: 18 additions & 0 deletions TestFoundation/TestImports.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
// This source file is part of the Swift.org open source project
//
// Copyright (c) 2014 - 2016 Apple Inc. and the Swift project authors
// Licensed under Apache License v2.0 with Runtime Library Exception
//
// See http://swift.org/LICENSE.txt for license information
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//

// Centralized conditional imports for all test sources

#if DEPLOYMENT_RUNTIME_OBJC || os(Linux) || os(Android)
@_exported import Foundation
@_exported import XCTest
#else
@_exported import SwiftFoundation
@_exported import SwiftXCTest
#endif
10 changes: 0 additions & 10 deletions TestFoundation/TestIndexPath.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,6 @@
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//


#if DEPLOYMENT_RUNTIME_OBJC || os(Linux)
import Foundation
import XCTest
#else
import SwiftFoundation
import SwiftXCTest
#endif


class TestIndexPath: XCTestCase {

static var allTests: [(String, (TestIndexPath) -> () throws -> Void)] {
Expand Down
10 changes: 0 additions & 10 deletions TestFoundation/TestIndexSet.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,6 @@
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//


#if DEPLOYMENT_RUNTIME_OBJC || os(Linux)
import Foundation
import XCTest
#else
import SwiftFoundation
import SwiftXCTest
#endif


class TestIndexSet : XCTestCase {

static var allTests: [(String, (TestIndexSet) -> () throws -> Void)] {
Expand Down
8 changes: 0 additions & 8 deletions TestFoundation/TestJSONEncoder.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,6 @@
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//

#if DEPLOYMENT_RUNTIME_OBJC || os(Linux)
import Foundation
import XCTest
#else
import SwiftFoundation
import SwiftXCTest
#endif

struct TopLevelObjectWrapper<T: Codable & Equatable>: Codable, Equatable {
var value: T

Expand Down
9 changes: 0 additions & 9 deletions TestFoundation/TestJSONSerialization.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,6 @@
// See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//


#if DEPLOYMENT_RUNTIME_OBJC || os(Linux)
import Foundation
import XCTest
#else
import SwiftFoundation
import SwiftXCTest
#endif

// Exposing internal ReadingOptions for tests.
extension JSONSerialization.ReadingOptions {
fileprivate static let useReferenceNumericTypes = JSONSerialization.ReadingOptions(rawValue: 1 << 15)
Expand Down
Loading