Skip to content

Commit 20bf328

Browse files
XstoudiSimonSchick
andauthored
doc: missing passed, error and passed properties on TestContext
`passed` and `error` properties were left undocumented on `TextContext` class Fixes: #59321 Refs: #51485 Refs: #59322 Co-authored-by: SimonSchick <[email protected]> PR-URL: #61185 Reviewed-By: Aviv Keller <[email protected]> Reviewed-By: Chemi Atlow <[email protected]> Reviewed-By: Colin Ihrig <[email protected]>
1 parent 2696391 commit 20bf328

File tree

1 file changed

+34
-0
lines changed

1 file changed

+34
-0
lines changed

doc/api/test.md

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3686,6 +3686,40 @@ added:
36863686

36873687
The name of the test.
36883688

3689+
### `context.passed`
3690+
3691+
<!-- YAML
3692+
added:
3693+
- v21.7.0
3694+
- v20.12.0
3695+
-->
3696+
3697+
* Type: {boolean} `false` before the test is executed, e.g. in a `beforeEach` hook.
3698+
3699+
Indicated whether the test succeeded.
3700+
3701+
### `context.error`
3702+
3703+
<!-- YAML
3704+
added:
3705+
- v21.7.0
3706+
- v20.12.0
3707+
-->
3708+
3709+
* Type: {Error|null}
3710+
3711+
The failure reason for the test/case; wrapped and available via `context.error.cause`.
3712+
3713+
### `context.attempt`
3714+
3715+
<!-- YAML
3716+
added: v25.0.0
3717+
-->
3718+
3719+
* Type: {number}
3720+
3721+
Number of times the test has been attempted.
3722+
36893723
### `context.plan(count[,options])`
36903724

36913725
<!-- YAML

0 commit comments

Comments
 (0)