# FerroTestIsolationLevel

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-headless/enum-ferrotestisolationlevel/

**enum** · [`ferroui-headless`](/docs/0.5.0/api/ferroui-headless/) · v0.5.0

```rust
enum FerroTestIsolationLevel
```

Defines the isolation level for headless unit tests, controlling how the
application and its associated dispatcher are managed between test runs.

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Headless/FerroUI.Headless/headless_unit_test_isolation_attribute.rs#L13)

## Members

- [`PerAssembly`](#variant-perassembly)
- [`PerTest`](#variant-pertest)

<a id="variant-perassembly"></a>

### PerAssembly

```rust
PerAssembly
```

Reuses a single application and dispatcher instance across all tests
within the assembly.

Tests must not rely on any global or persistent state that could
leak between runs. Headless framework won't dispose any resources
after tests when using this mode.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Headless/FerroUI.Headless/headless_unit_test_isolation_attribute.rs#L20)

<a id="variant-pertest"></a>

### PerTest

```rust
PerTest
```

Recreates the application and dispatcher for each individual test
method.

This mode ensures complete test isolation, and should be used for
tests that modify global application state or rely on a clean
dispatcher environment. This is the default isolation level if none
is specified.

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/Headless/FerroUI.Headless/headless_unit_test_isolation_attribute.rs#L29)

## Trait implementations

- `Send`
- `Sync`
- `Freeze`
- `UnsafeUnpin`
- `Unpin`
- `UnwindSafe`
- `RefUnwindSafe`
- `Borrow<T>`
- `BorrowMut<T>`
- `CloneToUninit`
- `Into<U>`
- `From<T>`
- `TryInto<U>`
- `TryFrom<U>`
- `Any`
- `ToOwned`
- [`ResourceKeyObject`](/docs/0.5.0/api/ferroui-base/controls/trait-resourcekeyobject/)
- [`PropertyValue`](/docs/0.5.0/api/ferroui-base/trait-propertyvalue/)
- [`AnyValue`](/docs/0.5.0/api/ferroui-base/trait-anyvalue/)
- [`ClassDefaults`](/docs/0.5.0/api/ferroui-base/trait-classdefaults/)
- `Clone`
- `Copy`
- `Debug`
- `StructuralPartialEq`
- `PartialEq`
- `Eq`
- `Hash`
- `ErasedDestructor`
- `IntoEither`

## Availability

Extracted for `x86_64-unknown-linux-gnu`, `aarch64-apple-darwin`. Cargo features are listed in the [crate index](/docs/0.5.0/api/).
