Creates a Canceled outcome given a string message.
Creates a Canceled outcome given a string message.
For example, trait CancelAfterFailure uses this factory method to create
a Canceled status if a cancelRemaining flag is set, which will
be the case if a test failed previously while running the suite:
abstract override def withFixture(test: NoArgTest): Outcome = { if (cancelRemaining) Canceled("Canceled by CancelOnFailure because a test failed previously") else super.withFixture(test) match { case failed: Failed => cancelRemaining = true failed case outcome => outcome } }
Creates a Canceled instance with the passed in Throwable.
Creates a Canceled instance with the passed in Throwable. If the passed in Throwable is a TestCanceledException,
it will be set as exception field, in other case a new TestCanceledException will be created using ex as its cause
the passed in Throwable
An instance of Canceled with ex set as its exception field if ex is a TestCanceledException, or a newly created TestCanceledException with ex set as its cause if ex is not a TestCanceledException.
Creates a Canceled instance with the passed in message and cause.
Creates a Canceled instance with the passed in message and cause.
the message for the TestCanceledException set as its exception field
the cause for the TestCanceledException set as its exception field
An instance of Canceled with a TestCanceledException created from passed in message and cause set as its exception field.
Creates a Canceled instance, with a TestCanceledException set as its exception field.
Creates a Canceled instance, with a TestCanceledException set as its exception field.
An instance of Canceled with a TestCanceledException set as its exception field.
Creates a Canceled with the passed in cause.
Creates a Canceled with the passed in cause.
the passed in cause
A Canceled with exception field set to a newly created TestCanceledException using the passed in cause.
Companion object to class
Canceledthat provides, in addition to the extractor and factory method provided by the compiler given its companion is a case class, a second factory method that produces aCanceledoutcome given a string message.