Skip to content

Commit ab8ffd1

Browse files
author
Mike Ferris
committed
Merge pull request #270 from briancroom/update_allTests
Update to support the latest Corelibs XCTest
2 parents 2c07d38 + 6f34430 commit ab8ffd1

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

46 files changed

+97
-97
lines changed

TestFoundation/TestNSAffineTransform.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
class TestNSAffineTransform : XCTestCase {
2222
private let accuracyThreshold = 0.001
2323

24-
var allTests : [(String, () throws -> Void)] {
24+
static var allTests: [(String, TestNSAffineTransform -> () throws -> Void)] {
2525
return [
2626
("test_BasicConstruction", test_BasicConstruction),
2727
("test_IdentityTransformation", test_IdentityTransformation),

TestFoundation/TestNSArray.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import SwiftXCTest
2121

2222
class TestNSArray : XCTestCase {
2323

24-
var allTests : [(String, () throws -> Void)] {
24+
static var allTests: [(String, TestNSArray -> () throws -> Void)] {
2525
return [
2626
("test_BasicConstruction", test_BasicConstruction),
2727
("test_enumeration", test_enumeration),

TestFoundation/TestNSBundle.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121

2222
class TestNSBundle : XCTestCase {
2323

24-
var allTests : [(String, () throws -> Void)] {
24+
static var allTests: [(String, TestNSBundle -> () throws -> Void)] {
2525
return [
2626
("test_paths", test_paths),
2727
("test_resources", test_resources),

TestFoundation/TestNSByteCountFormatter.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121

2222
class TestNSByteCountFormatter : XCTestCase {
2323

24-
var allTests : [(String, () throws -> Void)] {
24+
static var allTests: [(String, TestNSByteCountFormatter -> () throws -> Void)] {
2525
return [
2626
("test_DefaultValues", test_DefaultValues)
2727
]

TestFoundation/TestNSCalendar.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ import CoreFoundation
1818

1919
class TestNSCalendar: XCTestCase {
2020

21-
var allTests : [(String, () throws -> Void)] {
21+
static var allTests: [(String, TestNSCalendar -> () throws -> Void)] {
2222
return [
2323
("test_gettingDatesOnGregorianCalendar", test_gettingDatesOnGregorianCalendar ),
2424
("test_gettingDatesOnHebrewCalendar", test_gettingDatesOnHebrewCalendar ),

TestFoundation/TestNSCharacterSet.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import SwiftXCTest
2121

2222
class TestNSCharacterSet : XCTestCase {
2323

24-
var allTests : [(String, () throws -> Void)] {
24+
static var allTests: [(String, TestNSCharacterSet -> () throws -> Void)] {
2525
return [
2626
("test_Predefines", test_Predefines),
2727
("test_Range", test_Range),

TestFoundation/TestNSData.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717

1818
class TestNSData: XCTestCase {
1919

20-
var allTests: [(String, () throws -> Void)] {
20+
static var allTests: [(String, TestNSData -> () throws -> Void)] {
2121
return [
2222
("test_description", test_description),
2323
("test_emptyDescription", test_emptyDescription),

TestFoundation/TestNSDate.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121

2222
class TestNSDate : XCTestCase {
2323

24-
var allTests : [(String, () throws -> Void)] {
24+
static var allTests: [(String, TestNSDate -> () throws -> Void)] {
2525
return [
2626
("test_BasicConstruction", test_BasicConstruction),
2727
("test_InitTimeIntervalSince1970", test_InitTimeIntervalSince1970),

TestFoundation/TestNSDictionary.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import SwiftXCTest
2121

2222
class TestNSDictionary : XCTestCase {
2323

24-
var allTests : [(String, () throws -> Void)] {
24+
static var allTests: [(String, TestNSDictionary -> () throws -> Void)] {
2525
return [
2626
("test_BasicConstruction", test_BasicConstruction),
2727
("test_ArrayConstruction", test_ArrayConstruction),

TestFoundation/TestNSFileManager.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717

1818
class TestNSFileManger : XCTestCase {
1919

20-
var allTests : [(String, () throws -> Void)] {
20+
static var allTests: [(String, TestNSFileManger -> () throws -> Void)] {
2121
return [
2222
("test_createDirectory", test_createDirectory ),
2323
("test_createFile", test_createFile ),

TestFoundation/TestNSGeometry.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020

2121
class TestNSGeometry : XCTestCase {
2222

23-
var allTests : [(String, () throws -> Void)] {
23+
static var allTests: [(String, TestNSGeometry -> () throws -> Void)] {
2424
return [
2525
("test_CGFloat_BasicConstruction", test_CGFloat_BasicConstruction),
2626
("test_CGFloat_Equality", test_CGFloat_Equality),

TestFoundation/TestNSHTTPCookie.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717

1818
class TestNSHTTPCookie: XCTestCase {
1919

20-
var allTests : [(String, () throws -> Void)] {
20+
static var allTests: [(String, TestNSHTTPCookie -> () throws -> Void)] {
2121
return [
2222
("test_BasicConstruction", test_BasicConstruction),
2323
("test_RequestHeaderFields", test_RequestHeaderFields)

TestFoundation/TestNSIndexPath.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919

2020
class TestNSIndexPath: XCTestCase {
2121

22-
var allTests: [(String, () throws -> Void)] {
22+
static var allTests: [(String, TestNSIndexPath -> () throws -> Void)] {
2323
return [
2424
("test_BasicConstruction", test_BasicConstruction)
2525
]

TestFoundation/TestNSIndexSet.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ import SwiftXCTest
1919

2020
class TestNSIndexSet : XCTestCase {
2121

22-
var allTests : [(String, () throws -> Void)] {
22+
static var allTests: [(String, TestNSIndexSet -> () throws -> Void)] {
2323
return [
2424
("test_BasicConstruction", test_BasicConstruction),
2525
("test_enumeration", test_enumeration),

TestFoundation/TestNSJSONSerialization.swift

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ class TestNSJSONSerialization : XCTestCase {
2525
NSUTF32LittleEndianStringEncoding, NSUTF32BigEndianStringEncoding
2626
]
2727

28-
var allTests : [(String, () throws -> Void)] {
28+
static var allTests: [(String, TestNSJSONSerialization -> () throws -> Void)] {
2929
return JSONObjectWithDataTests
3030
+ deserializationTests
3131
+ isValidJSONObjectTests
@@ -36,7 +36,7 @@ class TestNSJSONSerialization : XCTestCase {
3636
//MARK: - JSONObjectWithData
3737
extension TestNSJSONSerialization {
3838

39-
var JSONObjectWithDataTests: [(String, () throws -> Void)] {
39+
class var JSONObjectWithDataTests: [(String, TestNSJSONSerialization -> () throws -> Void)] {
4040
return [
4141
("test_JSONObjectWithData_emptyObject", test_JSONObjectWithData_emptyObject),
4242
("test_JSONObjectWithData_encodingDetection", test_JSONObjectWithData_encodingDetection),
@@ -84,7 +84,7 @@ extension TestNSJSONSerialization {
8484
//MARK: - JSONDeserialization
8585
extension TestNSJSONSerialization {
8686

87-
var deserializationTests: [(String, () throws -> Void)] {
87+
class var deserializationTests: [(String, TestNSJSONSerialization -> () throws -> Void)] {
8888
return [
8989
("test_deserialize_emptyObject", test_deserialize_emptyObject),
9090
("test_deserialize_multiStringObject", test_deserialize_multiStringObject),
@@ -456,7 +456,7 @@ extension TestNSJSONSerialization {
456456
// MARK: - isValidJSONObjectTests
457457
extension TestNSJSONSerialization {
458458

459-
var isValidJSONObjectTests: [(String, () throws -> Void)] {
459+
class var isValidJSONObjectTests: [(String, TestNSJSONSerialization -> () throws -> Void)] {
460460
return [
461461
("test_isValidJSONObjectTrue", test_isValidJSONObjectTrue),
462462
("test_isValidJSONObjectFalse", test_isValidJSONObjectFalse),

TestFoundation/TestNSKeyedArchiver.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ public class UserClass : NSObject, NSSecureCoding {
5151
}
5252

5353
class TestNSKeyedArchiver : XCTestCase {
54-
var allTests : [(String, () throws -> Void)] {
54+
static var allTests: [(String, TestNSKeyedArchiver -> () throws -> Void)] {
5555
return [
5656
("test_archive_array", test_archive_array),
5757
("test_archive_charptr", test_archive_charptr),

TestFoundation/TestNSKeyedUnarchiver.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818

1919

2020
class TestNSKeyedUnarchiver : XCTestCase {
21-
var allTests : [(String, () throws -> Void)] {
21+
static var allTests: [(String, TestNSKeyedUnarchiver -> () throws -> Void)] {
2222
return [
2323
("test_unarchive_array", test_unarchive_array),
2424
("test_unarchive_complex", test_unarchive_complex),

TestFoundation/TestNSLocale.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
#endif
1717

1818
class TestNSLocale : XCTestCase {
19-
var allTests : [(String, () throws -> Void)] {
19+
static var allTests: [(String, TestNSLocale -> () throws -> Void)] {
2020
return [
2121
("test_constants", test_constants),
2222
]

TestFoundation/TestNSNotificationCenter.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818

1919

2020
class TestNSNotificationCenter : XCTestCase {
21-
var allTests : [(String, () throws -> Void)] {
21+
static var allTests: [(String, TestNSNotificationCenter -> () throws -> Void)] {
2222
return [
2323
("test_defaultCenter", test_defaultCenter),
2424
("test_postNotification", test_postNotification),

TestFoundation/TestNSNotificationQueue.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717

1818

1919
class TestNSNotificationQueue : XCTestCase {
20-
var allTests : [(String, () throws -> ())] {
20+
static var allTests : [(String, TestNSNotificationQueue -> () throws -> Void)] {
2121
return [
2222
("test_defaultQueue", test_defaultQueue),
2323
("test_postNowToDefaultQueueWithoutCoalescing", test_postNowToDefaultQueueWithoutCoalescing),

TestFoundation/TestNSNull.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121

2222
class TestNSNull : XCTestCase {
2323

24-
var allTests: [(String, () throws -> Void)] {
24+
static var allTests: [(String, TestNSNull -> () throws -> Void)] {
2525
return [
2626
("test_alwaysEqual", test_alwaysEqual)
2727
]

TestFoundation/TestNSNumber.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ import SwiftXCTest
1818

1919

2020
class TestNSNumber : XCTestCase {
21-
var allTests : [(String, () throws -> Void)] {
21+
static var allTests: [(String, TestNSNumber -> () throws -> Void)] {
2222
return [
2323
("test_NumberWithBool", test_NumberWithBool ),
2424
("test_numberWithChar", test_numberWithChar ),

TestFoundation/TestNSNumberFormatter.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ import CoreFoundation
1818

1919
class TestNSNumberFormatter: XCTestCase {
2020

21-
var allTests : [(String, () throws -> Void)] {
21+
static var allTests: [(String, TestNSNumberFormatter -> () throws -> Void)] {
2222
return [
2323
("test_currencyCode", test_currencyCode),
2424
("test_decimalSeparator", test_decimalSeparator),

TestFoundation/TestNSOrderedSet.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121

2222
class TestNSOrderedSet : XCTestCase {
2323

24-
var allTests : [(String, () throws -> Void)] {
24+
static var allTests: [(String, TestNSOrderedSet -> () throws -> Void)] {
2525
return [
2626
("test_BasicConstruction", test_BasicConstruction),
2727
("test_Enumeration", test_Enumeration),

TestFoundation/TestNSPipe.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ import SwiftXCTest
1919

2020
class TestNSPipe : XCTestCase {
2121

22-
var allTests: [(String, () throws -> Void)] {
22+
static var allTests: [(String, TestNSPipe -> () throws -> Void)] {
2323
return [
2424
// Currently disabled until NSString implements dataUsingEncoding
2525
// ("test_NSPipe", test_NSPipe)

TestFoundation/TestNSProcessInfo.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919

2020
class TestNSProcessInfo : XCTestCase {
2121

22-
var allTests : [(String, () throws -> Void)] {
22+
static var allTests: [(String, TestNSProcessInfo -> () throws -> Void)] {
2323
return [
2424
("test_operatingSystemVersion", test_operatingSystemVersion ),
2525
("test_processName", test_processName ),

TestFoundation/TestNSPropertyList.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ import SwiftXCTest
1919

2020

2121
class TestNSPropertyList : XCTestCase {
22-
var allTests : [(String, () throws -> Void)] {
22+
static var allTests: [(String, TestNSPropertyList -> () throws -> Void)] {
2323
return [
2424
("test_BasicConstruction", test_BasicConstruction ),
2525
("test_decode", test_decode ),

TestFoundation/TestNSRange.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ import SwiftXCTest
1919

2020
class TestNSRange : XCTestCase {
2121

22-
var allTests : [(String, () throws -> Void)] {
22+
static var allTests: [(String, TestNSRange -> () throws -> Void)] {
2323
return [
2424
// currently disabled due to pending requirements for NSString
2525
// ("test_NSRangeFromString", test_NSRangeFromString ),

TestFoundation/TestNSRegularExpression.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import SwiftXCTest
2121

2222
class TestNSRegularExpression : XCTestCase {
2323

24-
var allTests : [(String, () throws -> ())] {
24+
static var allTests : [(String, TestNSRegularExpression -> () throws -> Void)] {
2525
return [
2626
("test_simpleRegularExpressions", test_simpleRegularExpressions),
2727
("test_regularExpressionReplacement", test_regularExpressionReplacement)

TestFoundation/TestNSRunLoop.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717

1818

1919
class TestNSRunLoop : XCTestCase {
20-
var allTests : [(String, () throws -> ())] {
20+
static var allTests : [(String, TestNSRunLoop -> () throws -> Void)] {
2121
return [
2222
("test_constants", test_constants),
2323
("test_runLoopInit", test_runLoopInit),

TestFoundation/TestNSScanner.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121

2222
class TestNSScanner : XCTestCase {
2323

24-
var allTests : [(String, () throws -> Void)] {
24+
static var allTests: [(String, TestNSScanner -> () throws -> Void)] {
2525
return [
2626
("test_scanInteger", test_scanInteger),
2727
]

TestFoundation/TestNSSet.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import SwiftXCTest
2121

2222
class TestNSSet : XCTestCase {
2323

24-
var allTests : [(String, () throws -> Void)] {
24+
static var allTests: [(String, TestNSSet -> () throws -> Void)] {
2525
return [
2626
("test_BasicConstruction", test_BasicConstruction),
2727
("testInitWithSet", testInitWithSet),

TestFoundation/TestNSString.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ internal let kCFStringEncodingUTF32LE = CFStringBuiltInEncodings.UTF32LE.rawVal
3838

3939
class TestNSString : XCTestCase {
4040

41-
var allTests : [(String, () throws -> Void)] {
41+
static var allTests: [(String, TestNSString -> () throws -> Void)] {
4242
return [
4343
("test_boolValue", test_boolValue ),
4444
("test_BridgeConstruction", test_BridgeConstruction ),
@@ -81,7 +81,7 @@ class TestNSString : XCTestCase {
8181
("test_ExternalRepresentation", test_ExternalRepresentation),
8282
("test_mutableStringConstructor", test_mutableStringConstructor),
8383
("test_PrefixSuffix", test_PrefixSuffix),
84-
("test_reflection", test_reflection),
84+
("test_reflection", { _ in test_reflection }),
8585
]
8686
}
8787

TestFoundation/TestNSTask.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
import CoreFoundation
1818

1919
class TestNSTask : XCTestCase {
20-
var allTests: [(String, () throws -> Void)] {
20+
static var allTests: [(String, TestNSTask -> () throws -> Void)] {
2121
return [("test_exit0" , test_exit0),
2222
("test_exit1" , test_exit1),
2323
("test_exit100" , test_exit100),

TestFoundation/TestNSThread.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818

1919

2020
class TestNSThread : XCTestCase {
21-
var allTests : [(String, () throws -> Void)] {
21+
static var allTests: [(String, TestNSThread -> () throws -> Void)] {
2222
return [
2323
("test_currentThread", test_currentThread ),
2424
("test_threadStart", test_threadStart),

TestFoundation/TestNSTimeZone.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121

2222
class TestNSTimeZone: XCTestCase {
2323

24-
var allTests : [(String, () throws -> Void)] {
24+
static var allTests: [(String, TestNSTimeZone -> () throws -> Void)] {
2525
return [
2626
// Disabled see https://bugs.swift.org/browse/SR-300
2727
// ("test_abbreviation", test_abbreviation),

TestFoundation/TestNSTimer.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818

1919

2020
class TestNSTimer : XCTestCase {
21-
var allTests : [(String, () throws -> ())] {
21+
static var allTests : [(String, TestNSTimer -> () throws -> Void)] {
2222
return [
2323
("test_timerInit", test_timerInit),
2424
("test_timerTickOnce", test_timerTickOnce),

TestFoundation/TestNSURL.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ private func getTestData() -> [Any]? {
5353
}
5454

5555
class TestNSURL : XCTestCase {
56-
var allTests : [(String, () throws -> Void)] {
56+
static var allTests: [(String, TestNSURL -> () throws -> Void)] {
5757
return [
5858
("test_URLStrings", test_URLStrings),
5959
("test_fileURLWithPath_relativeToURL", test_fileURLWithPath_relativeToURL ),
@@ -420,7 +420,7 @@ class TestNSURL : XCTestCase {
420420
}
421421

422422
class TestNSURLComponents : XCTestCase {
423-
var allTests : [(String, () throws -> Void)] {
423+
static var allTests: [(String, TestNSURLComponents -> () throws -> Void)] {
424424
return [
425425
("test_string", test_string),
426426
]

TestFoundation/TestNSURLRequest.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818

1919
class TestNSURLRequest : XCTestCase {
2020

21-
var allTests : [(String, () throws -> Void)] {
21+
static var allTests: [(String, TestNSURLRequest -> () throws -> Void)] {
2222
return [
2323
("test_construction", test_construction),
2424
("test_mutableConstruction", test_mutableConstruction),

0 commit comments

Comments
 (0)