org.scalatest.events

TestStarting

class TestStarting(ordinal: Ordinal, suiteName: String, suiteClassName: Option[String], testName: String, formatter: Option[Formatter], rerunner: Option[Rerunner], payload: Option[Any], threadName: String, timeStamp: Long) extends Event with Product

Event that indicates a suite (or other entity) is about to start running a test.

For example, trait Suite uses TestStarting to report that a test method of a Suite is about to be invoked.

To create instances of this class you may use one of the factory methods provided in its companion object. For example, given a report function named report, you could fire a TestStarting event like this:

report(TestStarting(ordinal, userFriendlyName, suiteName, Some(thisSuite.getClass.getName), testName))

The suite class name parameter is optional, because suites in ScalaTest are an abstraction that need not necessarily correspond to one class. Nevertheless, it most cases each suite will correspond to a class, and when it does, the fully qualified name of that class should be reported by passing aSome for suiteClassName. One use for this bit of information is JUnit integration, because the "name" provided to a JUnit org.junit.runner.Description appears to usually include a fully qualified class name by convention.

ordinal

an Ordinal that can be used to place this event in order in the context of other events reported during the same run

suiteName

the name of the suite containing the test that is starting

suiteClassName

an optional fully qualifed Suite class name containing the test that is starting

testName

the name of the test that is starting

formatter

an optional formatter that provides extra information that can be used by reporters in determining how to present this event to the user

rerunner

an optional Rerunner that can be used to rerun the test that is starting (if None is passed, the test cannot be rerun)

payload

an optional object that can be used to pass custom information to the reporter about the TestStarting event

threadName

a name for the Thread about whose activity this event was reported

timeStamp

a Long indicating the time this event was reported, expressed in terms of the number of milliseconds since the standard base time known as "the epoch": January 1, 1970, 00:00:00 GMT

attributes: final
go to: companion
    authors:
  1. Bill Venners

Inherited
  1. Hide All
  2. Show all
  1. Product
  2. Equals
  3. Event
  4. Ordered
  5. Comparable
  6. AnyRef
  7. Any
Visibility
  1. Public
  2. All

Instance constructors

  1. new TestStarting(ordinal: Ordinal, suiteName: String, suiteClassName: Option[String], testName: String, formatter: Option[Formatter], rerunner: Option[Rerunner], payload: Option[Any], threadName: String, timeStamp: Long)

Value Members

  1. def !=(arg0: AnyRef): Boolean

  2. def !=(arg0: Any): Boolean

    o != arg0 is the same as !(o == (arg0)).

  3. def ##(): Int

  4. def $asInstanceOf[T0](): T0

  5. def $isInstanceOf[T0](): Boolean

  6. def <(that: Event): Boolean

  7. def <=(that: Event): Boolean

  8. def ==(arg0: AnyRef): Boolean

    o == arg0 is the same as if (o eq null) arg0 eq null else o.equals(arg0).

  9. def ==(arg0: Any): Boolean

    o == arg0 is the same as o.equals(arg0).

  10. def >(that: Event): Boolean

  11. def >=(that: Event): Boolean

  12. def asInstanceOf[T0]: T0

    This method is used to cast the receiver object to be of type T0.

  13. def canEqual(arg0: Any): Boolean

  14. def clone(): AnyRef

    This method creates and returns a copy of the receiver object.

  15. def compare(that: Event): Int

    Comparing this event with the event passed as that.

  16. def compareTo(that: Event): Int

  17. def eq(arg0: AnyRef): Boolean

    This method is used to test whether the argument (arg0) is a reference to the receiver object (this).

  18. def equals(arg0: Any): Boolean

    This method is used to compare the receiver object (this) with the argument object (arg0) for equivalence.

  19. def finalize(): Unit

    This method is called by the garbage collector on the receiver object when garbage collection determines that there are no more references to the object.

  20. val formatter: Option[Formatter]

    An optional formatter that provides extra information that can be used by reporters in determining how to present this event to the user.

  21. def getClass(): java.lang.Class[_]

    Returns a representation that corresponds to the dynamic class of the receiver object.

  22. def hashCode(): Int

    Returns a hash code value for the object.

  23. def isInstanceOf[T0]: Boolean

    This method is used to test whether the dynamic type of the receiver object is T0.

  24. def ne(arg0: AnyRef): Boolean

    o.ne(arg0) is the same as !(o.eq(arg0)).

  25. def notify(): Unit

    Wakes up a single thread that is waiting on the receiver object's monitor.

  26. def notifyAll(): Unit

    Wakes up all threads that are waiting on the receiver object's monitor.

  27. val ordinal: Ordinal

    An Ordinal that can be used to place this event in order in the context of other events reported during the same run.

  28. val payload: Option[Any]

    An optional object that can be used to pass custom information to the reporter about this event.

  29. def productArity: Int

  30. def productElement(arg0: Int): Any

  31. def productElements: Iterator[Any]

  32. def productIterator: Iterator[Any]

  33. def productPrefix: String

  34. val rerunner: Option[Rerunner]

  35. val suiteClassName: Option[String]

  36. val suiteName: String

  37. def synchronized[T0](arg0: T0): T0

  38. val testName: String

  39. val threadName: String

    A name for the Thread about whose activity this event was reported.

  40. val timeStamp: Long

    A Long indicating the time this event was reported, expressed in terms of the number of milliseconds since the standard base time known as "the epoch": January 1, 1970, 00:00:00 GMT.

  41. def toString(): String

    Returns a string representation of the object.

  42. def wait(): Unit

  43. def wait(arg0: Long, arg1: Int): Unit

  44. def wait(arg0: Long): Unit