Class

XCTNSPredicateExpectation

An expectation that is fulfilled when an NSPredicate is satisfied.

Topics

Creating a Predicate-Based Expectation

init(predicate: NSPredicate, object: Any?)

Creates an expectation that is fulfilled when an NSPredicate instance returns true, optionally for a provided object.

Expectation Properties

var predicate: NSPredicate

The predicate that is evaluated by the expectation.

var object: Any?

An optional object against which the predicate is evaluated.

Handling Predicate Resolution

var handler: XCTNSPredicateExpectation.Handler?

An optional handler that performs custom evaluation when predicate evaluates as true.

typealias XCTNSPredicateExpectation.Handler

A handler to be called when evaluating the predicate returns true.

Relationships

Inherits From