Skip to content

API Reference / @gtkx/testing / getElementError

Function: getElementError() ​

getElementError(message, container?): Error

Defined in: packages/testing/src/errors.ts:141

Builds the error a failing query throws, appending the container's widget tree to the message the way the built-in queries do.

Parameters ​

message ​

string

The failure message.

container? ​

Container

The scope whose widget tree is appended; omitted, only the message is used.

Returns ​

Error

The error produced by the configured getElementError.