# TestAll(int, int)

> Returns true if all of the bits in a contiguous range are 1.

## Definition

* **Type:** Method
* **Namespace:** [Unity.Collections](/engine/6000.7/script-reference/unity/collections.md)
* **Assembly:** UnityEngine.ManagedKernelModule

```csharp
public bool TestAll(int pos, int numBits = 1)
```

### Parameters

**** (\[int]\(https\://learn.microsoft.com/dotnet/api/system.int32)): Position in the bit field (must be 0-63).**** (\[int]\(https\://learn.microsoft.com/dotnet/api/system.int32)): Number of bits to test (must be 1-64).

### Returns

| Type                                                          | Description                                     |
| ------------------------------------------------------------- | ----------------------------------------------- |
| [bool](https://learn.microsoft.com/dotnet/api/system.boolean) | True if all bits in the contiguous range are 1. |
