externalErrorBlock <NET>
Hierarchy
- InteractionObject<NET>
- ErrorBlock
Index
Constructors
Methods
Constructors
externalconstructor
Type parameters
- NET
Parameters
externalrootElement: PageElement<NET> | QuestionAdapter<PageElement<NET>>
externaloptionaloptions: InteractionObjectOptions
Returns ErrorBlock<NET>
Methods
externalisPresent
Checks whether the interaction object's root element is present in the DOM.
Since
InteractionObjectimplementsOptional, you can assert on presence directly:Ensure.that(view, isPresent())Returns Answerable<boolean>
externalname
The error type/class name (e.g.
'AssertionError','TimeoutError').Example
Ensure.that(errorBlock.name(), equals('AssertionError'))Returns QuestionAdapter<string>
externalmessage
The error message text.
Example
Ensure.that(errorBlock.message(), includes('expected true to equal false'))Returns QuestionAdapter<string>
externalstackTrace
The full stack trace text rendered in the error block.
Example
Ensure.that(errorBlock.stackTrace(), includes('checkout.spec.ts:42'))Returns QuestionAdapter<string>
externalhasLocation
Whether the error block displays a source location with a copy affordance.
Example
Ensure.that(errorBlock.hasLocation(), equals(true))Returns Question<Promise<boolean>>
Interaction object representing an error display block in the scenario detail view.
Shows the error name (type), message, and stack trace for a failed scenario. Obtained via ScenarioDetailView.errorBlock — not instantiated directly in tests.
Usage in a test