---
title: "waiter(_:fulfillmentDidViolateOrderingConstraintsFor:requiredExpectation:)"
framework: xctest
role: symbol
role_heading: Instance Method
path: "xctest/xctwaiterdelegate/waiter(_:fulfillmentdidviolateorderingconstraintsfor:requiredexpectation:)"
---

# waiter(_:fulfillmentDidViolateOrderingConstraintsFor:requiredExpectation:)

Invoked when a waiter is enforcing fulfillment order and an expectation is fulfilled in the wrong order.

## Declaration

```swift
optional func waiter(_ waiter: XCTWaiter, fulfillmentDidViolateOrderingConstraintsFor expectation: XCTestExpectation, requiredExpectation: XCTestExpectation)
```

## Discussion

Discussion If the delegate is an XCTestCase instance, this will be reported as a test failure.
