Options
All
  • Public
  • Public/Protected
  • All
Menu

Class TestResult

Hierarchy

  • TestResult

Index

Constructors

constructor

Methods

addError

  • Adds an error to the list of errors. The passed in exception caused the error.

    Parameters

    Returns void

addFailure

  • Adds a failure to the list of failures. The passed in exception caused the failure.

    Parameters

    Returns void

addListener

  • Registers a TestListener

    Parameters

    Returns void

endTest

  • Informs the result that a test was completed.

    Parameters

    Returns void

errorCount

  • errorCount(): number
  • Gets the number of detected errors.

    Returns number

errors

  • errors(): {}
  • Returns {}

    • [key: string]: T

failureCount

  • failureCount(): number
  • Gets the number of detected failures.

    Returns number

failures

  • failures(): {}
  • Returns {}

    • [key: string]: T

isSuccessTestMethod

  • isSuccessTestMethod(methodName: string, caseName: string): boolean
  • Parameters

    • methodName: string
    • caseName: string

    Returns boolean

removeListener

  • Unregisters a TestListener

    Parameters

    Returns void

run

  • Runs a TestCase.

    Parameters

    Returns void

runCount

  • runCount(): number
  • Gets the number of run tests.

    Returns number

shouldStop

  • shouldStop(): boolean
  • Checks whether the test run should stop

    Returns boolean

startTest

  • Informs the result that a test will be started.

    Parameters

    Returns void

stop

  • stop(): void
  • Marks that the test run should stop.

    Returns void

wasSuccessful

  • wasSuccessful(): boolean
  • Returns whether the entire test was successful or not.

    Returns boolean