Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion docs/articles/nunit/writing-tests/attributes/cancelafter.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,11 @@ to check this token, either directly or indirectly.
The specified timeout value covers the test setup and teardown as well as the test method itself. Before and after
actions may also be included, depending on where they were specified. Since the timeout may occur during any of these
execution phases, no guarantees can be made as to what will be run and any of these phases of execution may be
incomplete. If only used on a test, once a test has timed out, its teardown methods are executed.
incomplete. If only used on a test, once a test has timed out, its teardown methods are executed. NUnit will ensure
that the cancellation token will be available across all these phases. This also means that the token will be in the
"cancelled" state in one phase (ex: `TearDown`) if it were marked as cancelled during a previous phase. It therefore
should be used with caution in `TearDown` phases when getting passed down to other methods which perform cleanup as
an already-cancelled token may prevent HTTP or DB calls from being performed.

The attribute may also be specified on a fixture, in which case it indicates the default timeout for any subordinate
test cases. When using the console runner, it is also possible to specify a default timeout on the command-line.
Expand Down