Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Xcode 9 Support (Swift 3.2) #446

Merged
merged 10 commits into from
Aug 3, 2017
28 changes: 20 additions & 8 deletions Nimble.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -297,7 +297,7 @@
1FD8CD5A1968AB07008ED995 /* Equal.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1FD8CD1C1968AB07008ED995 /* Equal.swift */; };
1FD8CD5B1968AB07008ED995 /* Equal.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1FD8CD1C1968AB07008ED995 /* Equal.swift */; };
1FD8CD5C1968AB07008ED995 /* MatcherProtocols.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1FD8CD1D1968AB07008ED995 /* MatcherProtocols.swift */; };
1FD8CD5D1968AB07008ED995 /* MatcherProtocols.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1FD8CD1D1968AB07008ED995 /* MatcherProtocols.swift */; };
1FD8CD5D1968AB07008ED995 /* MatcherProtocols.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1FD8CD1D1968AB07008ED995 /* MatcherProtocols.swift */; };
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wrong indentation.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is generated by Xcode.. do you really expect me to fix this?

Not trying to be difficult just pragmatic. :)

1FD8CD5E1968AB07008ED995 /* RaisesException.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1FD8CD1E1968AB07008ED995 /* RaisesException.swift */; };
1FD8CD5F1968AB07008ED995 /* RaisesException.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1FD8CD1E1968AB07008ED995 /* RaisesException.swift */; };
1FD8CD6A1968AB07008ED995 /* Async.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1FD8CD261968AB07008ED995 /* Async.swift */; };
Expand Down Expand Up @@ -1170,33 +1170,33 @@
isa = PBXProject;
attributes = {
LastSwiftUpdateCheck = 0730;
LastUpgradeCheck = 0820;
LastUpgradeCheck = 0900;
ORGANIZATIONNAME = "Jeff Hui";
TargetAttributes = {
1F1A74281940169200FFFC47 = {
CreatedOnToolsVersion = 6.0;
LastSwiftMigration = 0800;
LastSwiftMigration = 0900;
};
1F1A74331940169200FFFC47 = {
CreatedOnToolsVersion = 6.0;
LastSwiftMigration = 0800;
LastSwiftMigration = 0900;
TestTargetID = 1F1A74281940169200FFFC47;
};
1F5DF1541BDCA0CE00C3A531 = {
CreatedOnToolsVersion = 7.1;
LastSwiftMigration = 0800;
LastSwiftMigration = 0900;
};
1F5DF15D1BDCA0CE00C3A531 = {
CreatedOnToolsVersion = 7.1;
LastSwiftMigration = 0800;
LastSwiftMigration = 0900;
};
1F925EAC195C0D6300ED456B = {
CreatedOnToolsVersion = 6.0;
LastSwiftMigration = 0800;
LastSwiftMigration = 0900;
};
1F925EB6195C0D6300ED456B = {
CreatedOnToolsVersion = 6.0;
LastSwiftMigration = 0800;
LastSwiftMigration = 0900;
TestTargetID = 1F925EAC195C0D6300ED456B;
};
A8F2B2541E79A4AB005BDD17 = {
Expand Down Expand Up @@ -1751,14 +1751,20 @@
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_MODULES_AUTOLINK = NO;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
Expand Down Expand Up @@ -1808,14 +1814,20 @@
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_MODULES_AUTOLINK = NO;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
Expand Down
4 changes: 3 additions & 1 deletion Nimble.xcodeproj/xcshareddata/xcschemes/Nimble-iOS.xcscheme
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "0820"
LastUpgradeVersion = "0900"
version = "2.0">
<BuildAction
parallelizeBuildables = "YES"
Expand All @@ -26,6 +26,7 @@
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
language = ""
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
<TestableReference
Expand All @@ -46,6 +47,7 @@
buildConfiguration = "Debug"
selectedDebuggerIdentifier = ""
selectedLauncherIdentifier = "Xcode.IDEFoundation.Launcher.PosixSpawn"
language = ""
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "0820"
LastUpgradeVersion = "0900"
version = "2.0">
<BuildAction
parallelizeBuildables = "YES"
Expand All @@ -26,6 +26,7 @@
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
language = ""
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
<TestableReference
Expand All @@ -46,6 +47,7 @@
buildConfiguration = "Debug"
selectedDebuggerIdentifier = ""
selectedLauncherIdentifier = "Xcode.IDEFoundation.Launcher.PosixSpawn"
language = ""
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
Expand Down
4 changes: 3 additions & 1 deletion Nimble.xcodeproj/xcshareddata/xcschemes/Nimble-tvOS.xcscheme
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "0820"
LastUpgradeVersion = "0900"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
Expand All @@ -26,6 +26,7 @@
buildConfiguration = "Debug"
selectedDebuggerIdentifier = ""
selectedLauncherIdentifier = "Xcode.IDEFoundation.Launcher.PosixSpawn"
language = ""
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
<TestableReference
Expand Down Expand Up @@ -55,6 +56,7 @@
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
language = ""
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
#if !SWIFT_PACKAGE && NON_SWIFT_PACKAGE
__attribute__((visibility("hidden")))
#endif
NSException* catchExceptionOfKind(Class __nonnull type, __attribute__((noescape)) void (^ __nonnull inBlock)()) {
NSException* catchExceptionOfKind(Class __nonnull type, __attribute__((noescape)) void (^ __nonnull inBlock)(void)) {
@try {
inBlock();
} @catch (NSException *exception) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,5 @@ FOUNDATION_EXPORT const unsigned char CwlCatchExceptionVersionString[];
#if !SWIFT_PACKAGE && NON_SWIFT_PACKAGE
__attribute__((visibility("hidden")))
#endif
NSException* __nullable catchExceptionOfKind(Class __nonnull type, __attribute__((noescape)) void (^ __nonnull inBlock)());
NSException* __nullable catchExceptionOfKind(Class __nonnull type, __attribute__((noescape)) void (^ __nonnull inBlock)(void));

4 changes: 2 additions & 2 deletions Sources/Nimble/Adapters/NMBExpectation.swift
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ public class NMBExpectation: NSObject {
internal let _line: UInt
internal var _timeout: TimeInterval = 1.0

public init(actualBlock: @escaping () -> NSObject!, negative: Bool, file: FileString, line: UInt) {
@objc public init(actualBlock: @escaping () -> NSObject!, negative: Bool, file: FileString, line: UInt) {
self._actualBlock = actualBlock
self._negative = negative
self._file = file
Expand Down Expand Up @@ -175,7 +175,7 @@ public class NMBExpectation: NSObject {

public var toNotEventuallyWithDescription: (NMBMatcher, String) -> Void { return toEventuallyNotWithDescription }

public class func failWithMessage(_ message: String, file: FileString, line: UInt) {
@objc public class func failWithMessage(_ message: String, file: FileString, line: UInt) {
fail(message, location: SourceLocation(file: file, line: line))
}
}
Expand Down
2 changes: 1 addition & 1 deletion Sources/Nimble/Matchers/AllPass.swift
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ private func createPredicate<S>(_ elementMatcher: Predicate<S.Iterator.Element>)

#if _runtime(_ObjC)
extension NMBObjCMatcher {
public class func allPassMatcher(_ matcher: NMBMatcher) -> NMBPredicate {
@objc public class func allPassMatcher(_ matcher: NMBMatcher) -> NMBPredicate {
return NMBPredicate { actualExpression in
let location = actualExpression.location
let actualValue = try! actualExpression.evaluate()
Expand Down
2 changes: 1 addition & 1 deletion Sources/Nimble/Matchers/BeAKindOf.swift
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ public func beAKindOf(_ expectedClass: AnyClass) -> Predicate<NSObject> {
}

extension NMBObjCMatcher {
public class func beAKindOfMatcher(_ expected: AnyClass) -> NMBMatcher {
@objc public class func beAKindOfMatcher(_ expected: AnyClass) -> NMBMatcher {
return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in
return try! beAKindOf(expected).matches(actualExpression, failureMessage: failureMessage)
}
Expand Down
2 changes: 1 addition & 1 deletion Sources/Nimble/Matchers/BeAnInstanceOf.swift
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public func beAnInstanceOf(_ expectedClass: AnyClass) -> Predicate<NSObject> {

#if _runtime(_ObjC)
extension NMBObjCMatcher {
public class func beAnInstanceOfMatcher(_ expected: AnyClass) -> NMBMatcher {
@objc public class func beAnInstanceOfMatcher(_ expected: AnyClass) -> NMBMatcher {
return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in
return try! beAnInstanceOf(expected).matches(actualExpression, failureMessage: failureMessage)
}
Expand Down
4 changes: 2 additions & 2 deletions Sources/Nimble/Matchers/BeCloseTo.swift
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import Foundation

internal let DefaultDelta = 0.0001
public let DefaultDelta = 0.0001

internal func isCloseTo(_ actualValue: NMBDoubleConvertible?,
expectedValue: NMBDoubleConvertible,
Expand Down Expand Up @@ -69,7 +69,7 @@ public class NMBObjCBeCloseToMatcher: NSObject, NMBMatcher {
}

extension NMBObjCMatcher {
public class func beCloseToMatcher(_ expected: NSNumber, within: CDouble) -> NMBObjCBeCloseToMatcher {
@objc public class func beCloseToMatcher(_ expected: NSNumber, within: CDouble) -> NMBObjCBeCloseToMatcher {
return NMBObjCBeCloseToMatcher(expected: expected, within: within)
}
}
Expand Down
2 changes: 1 addition & 1 deletion Sources/Nimble/Matchers/BeEmpty.swift
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ public func beEmpty() -> Predicate<NMBCollection> {

#if _runtime(_ObjC)
extension NMBObjCMatcher {
public class func beEmptyMatcher() -> NMBPredicate {
@objc public class func beEmptyMatcher() -> NMBPredicate {
return NMBPredicate { actualExpression in
let location = actualExpression.location
let actualValue = try! actualExpression.evaluate()
Expand Down
2 changes: 1 addition & 1 deletion Sources/Nimble/Matchers/BeGreaterThan.swift
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public func > (lhs: Expectation<NMBComparable>, rhs: NMBComparable?) {

#if _runtime(_ObjC)
extension NMBObjCMatcher {
public class func beGreaterThanMatcher(_ expected: NMBComparable?) -> NMBObjCMatcher {
@objc public class func beGreaterThanMatcher(_ expected: NMBComparable?) -> NMBObjCMatcher {
return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in
let expr = actualExpression.cast { $0 as? NMBComparable }
return try! beGreaterThan(expected).matches(expr, failureMessage: failureMessage)
Expand Down
2 changes: 1 addition & 1 deletion Sources/Nimble/Matchers/BeGreaterThanOrEqualTo.swift
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ public func >=<T: NMBComparable>(lhs: Expectation<T>, rhs: T) {

#if _runtime(_ObjC)
extension NMBObjCMatcher {
public class func beGreaterThanOrEqualToMatcher(_ expected: NMBComparable?) -> NMBObjCMatcher {
@objc public class func beGreaterThanOrEqualToMatcher(_ expected: NMBComparable?) -> NMBObjCMatcher {
return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in
let expr = actualExpression.cast { $0 as? NMBComparable }
return try! beGreaterThanOrEqualTo(expected).matches(expr, failureMessage: failureMessage)
Expand Down
2 changes: 1 addition & 1 deletion Sources/Nimble/Matchers/BeIdenticalTo.swift
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ public func be(_ expected: Any?) -> Predicate<Any> {

#if _runtime(_ObjC)
extension NMBObjCMatcher {
public class func beIdenticalToMatcher(_ expected: NSObject?) -> NMBObjCMatcher {
@objc public class func beIdenticalToMatcher(_ expected: NSObject?) -> NMBObjCMatcher {
return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in
let aExpr = actualExpression.cast { $0 as Any? }
return try! beIdenticalTo(expected).matches(aExpr, failureMessage: failureMessage)
Expand Down
2 changes: 1 addition & 1 deletion Sources/Nimble/Matchers/BeLessThan.swift
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public func < (lhs: Expectation<NMBComparable>, rhs: NMBComparable?) {

#if _runtime(_ObjC)
extension NMBObjCMatcher {
public class func beLessThanMatcher(_ expected: NMBComparable?) -> NMBObjCMatcher {
@objc public class func beLessThanMatcher(_ expected: NMBComparable?) -> NMBObjCMatcher {
return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in
let expr = actualExpression.cast { $0 as? NMBComparable }
return try! beLessThan(expected).matches(expr, failureMessage: failureMessage)
Expand Down
2 changes: 1 addition & 1 deletion Sources/Nimble/Matchers/BeLessThanOrEqual.swift
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ public func <=<T: NMBComparable>(lhs: Expectation<T>, rhs: T) {

#if _runtime(_ObjC)
extension NMBObjCMatcher {
public class func beLessThanOrEqualToMatcher(_ expected: NMBComparable?) -> NMBObjCMatcher {
@objc public class func beLessThanOrEqualToMatcher(_ expected: NMBComparable?) -> NMBObjCMatcher {
return NMBObjCMatcher(canMatchNil:false) { actualExpression, failureMessage in
let expr = actualExpression.cast { $0 as? NMBComparable }
return try! beLessThanOrEqualTo(expected).matches(expr, failureMessage: failureMessage)
Expand Down
8 changes: 4 additions & 4 deletions Sources/Nimble/Matchers/BeLogical.swift
Original file line number Diff line number Diff line change
Expand Up @@ -136,28 +136,28 @@ public func beFalsy<T: ExpressibleByBooleanLiteral & Equatable>() -> Predicate<T

#if _runtime(_ObjC)
extension NMBObjCMatcher {
public class func beTruthyMatcher() -> NMBObjCMatcher {
@objc public class func beTruthyMatcher() -> NMBObjCMatcher {
return NMBObjCMatcher { actualExpression, failureMessage in
let expr = actualExpression.cast { ($0 as? NSNumber)?.boolValue ?? false }
return try! beTruthy().matches(expr, failureMessage: failureMessage)
}
}

public class func beFalsyMatcher() -> NMBObjCMatcher {
@objc public class func beFalsyMatcher() -> NMBObjCMatcher {
return NMBObjCMatcher { actualExpression, failureMessage in
let expr = actualExpression.cast { ($0 as? NSNumber)?.boolValue ?? false }
return try! beFalsy().matches(expr, failureMessage: failureMessage)
}
}

public class func beTrueMatcher() -> NMBObjCMatcher {
@objc public class func beTrueMatcher() -> NMBObjCMatcher {
return NMBObjCMatcher { actualExpression, failureMessage in
let expr = actualExpression.cast { ($0 as? NSNumber)?.boolValue ?? false }
return try! beTrue().matches(expr, failureMessage: failureMessage)
}
}

public class func beFalseMatcher() -> NMBObjCMatcher {
@objc public class func beFalseMatcher() -> NMBObjCMatcher {
return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in
let expr = actualExpression.cast { ($0 as? NSNumber)?.boolValue ?? false }
return try! beFalse().matches(expr, failureMessage: failureMessage)
Expand Down
2 changes: 1 addition & 1 deletion Sources/Nimble/Matchers/BeNil.swift
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ public func beNil<T>() -> Predicate<T> {

#if _runtime(_ObjC)
extension NMBObjCMatcher {
public class func beNilMatcher() -> NMBObjCMatcher {
@objc public class func beNilMatcher() -> NMBObjCMatcher {
return NMBObjCMatcher { actualExpression, failureMessage in
return try! beNil().matches(actualExpression, failureMessage: failureMessage)
}
Expand Down
2 changes: 1 addition & 1 deletion Sources/Nimble/Matchers/BeginWith.swift
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public func beginWith(_ startingSubstring: String) -> Predicate<String> {

#if _runtime(_ObjC)
extension NMBObjCMatcher {
public class func beginWithMatcher(_ expected: Any) -> NMBObjCMatcher {
@objc public class func beginWithMatcher(_ expected: Any) -> NMBObjCMatcher {
return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in
let actual = try! actualExpression.evaluate()
if (actual as? String) != nil {
Expand Down
2 changes: 1 addition & 1 deletion Sources/Nimble/Matchers/Contain.swift
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ public func contain(_ items: [Any?]) -> Predicate<NMBContainer> {

#if _runtime(_ObjC)
extension NMBObjCMatcher {
public class func containMatcher(_ expected: [NSObject]) -> NMBObjCMatcher {
@objc public class func containMatcher(_ expected: [NSObject]) -> NMBObjCMatcher {
return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in
let location = actualExpression.location
let actualValue = try! actualExpression.evaluate()
Expand Down
2 changes: 1 addition & 1 deletion Sources/Nimble/Matchers/ContainElementSatisfying.swift
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ public func containElementSatisfying<S: Sequence, T>(_ predicate: @escaping ((T)

#if _runtime(_ObjC)
extension NMBObjCMatcher {
public class func containElementSatisfyingMatcher(_ predicate: @escaping ((NSObject) -> Bool)) -> NMBObjCMatcher {
@objc public class func containElementSatisfyingMatcher(_ predicate: @escaping ((NSObject) -> Bool)) -> NMBObjCMatcher {
return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in
let value = try! actualExpression.evaluate()
guard let enumeration = value as? NSFastEnumeration else {
Expand Down
2 changes: 1 addition & 1 deletion Sources/Nimble/Matchers/EndWith.swift
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ public func endWith(_ endingSubstring: String) -> Predicate<String> {

#if _runtime(_ObjC)
extension NMBObjCMatcher {
public class func endWithMatcher(_ expected: Any) -> NMBObjCMatcher {
@objc public class func endWithMatcher(_ expected: Any) -> NMBObjCMatcher {
return NMBObjCMatcher(canMatchNil: false) { actualExpression, failureMessage in
let actual = try! actualExpression.evaluate()
if (actual as? String) != nil {
Expand Down
Loading