[API reference](https://evolu.dev/docs/api-reference) › [@evolu/common](https://evolu.dev/docs/api-reference/common) › [Platform](https://evolu.dev/docs/api-reference/common/Platform) › TestGlobalErrors

Defined in: [packages/common/src/Platform.ts:104](https://github.com/evoluhq/evolu/blob/dd96d79f1dbe9a49fa12ce8e0aa7d3d0177795ca/packages/common/src/Platform.ts#L104)

Records platform global errors until disposed.

## Extends

- [`Disposable`](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-5-2.html#using-declarations-and-explicit-resource-management)

## Methods

<a id="dispose"></a>

### \[dispose\]()

```ts
dispose: void;
```

Defined in: node\_modules/@typescript/old/lib/lib.esnext.disposable.d.ts:34

#### Inherited from

```ts
Disposable.[dispose]
```

## Properties

<a id="errors"></a>

### errors

```ts
readonly errors: readonly unknown[];
```

Defined in: [packages/common/src/Platform.ts:105](https://github.com/evoluhq/evolu/blob/dd96d79f1dbe9a49fa12ce8e0aa7d3d0177795ca/packages/common/src/Platform.ts#L105)

---

<a id="next"></a>

### next

```ts
readonly next: () => Promise<unknown>;
```

Defined in: [packages/common/src/Platform.ts:106](https://github.com/evoluhq/evolu/blob/dd96d79f1dbe9a49fa12ce8e0aa7d3d0177795ca/packages/common/src/Platform.ts#L106)

### settle

```ts
readonly settle: () => Promise<readonly unknown[]>;
```

Defined in: [packages/common/src/Platform.ts:118](https://github.com/evoluhq/evolu/blob/dd96d79f1dbe9a49fa12ce8e0aa7d3d0177795ca/packages/common/src/Platform.ts#L118)

Waits until every error already reported to the platform has been delivered
to this recorder, then returns [TestGlobalErrors.errors](https://evolu.dev/docs/api-reference/common/Platform/interfaces/TestGlobalErrors#errors).

Platforms deliver global errors asynchronously and provide no hook for
"nothing was reported", so settle emits a sentinel of the same kind and
resolves when it arrives. Platform delivery is ordered, so all earlier
errors are recorded by then. Assert absence with `assertEqual(await
unhandledRejections.settle(), [])`.