---
title: "init(orTestWith:)"
framework: foundation
role: symbol
role_heading: Initializer
path: "foundation/nslogicaltest/init(ortestwith:)"
---

# init(orTestWith:)

Returns an NSLogicalTest object initialized to perform an OR operation with the NSSpecifierTest objects in a given array.

## Declaration

```swift
init(orTestWith subTests: [NSSpecifierTest])
```

## Parameters

- `subTests`: An array of NSSpecifierTest objects representing Boolean expressions.

## Return Value

Return Value An NSLogicalTest object initialized to perform an OR operation with the NSSpecifierTest objects in subTests.

## See Also

### Initializing a logical test

- [init(andTestWith:)](foundation/nslogicaltest/init(andtestwith:).md)
- [init(notTestWith:)](foundation/nslogicaltest/init(nottestwith:).md)
