Package io.cucumber.core.plugin
Class CanonicalEventOrder
java.lang.Object
io.cucumber.core.plugin.CanonicalEventOrder
- All Implemented Interfaces:
Comparator<Event>
When pickles are executed in parallel events can be produced with a partial
ordering.
The canonical order is the order in which these events would have been generated had cucumber executed these pickles in a serial fashion.
In canonical order events are ordered by type and time stamp:
- TestRunStarted
- TestSourceRead
- TestSourceParsed
- SnippetsSuggestedEvent
- StepDefinedEvent
- TestCaseEvent
- TestRunFinished
As part of ordering events by type, TestCaseEvents are ordered by
- uri
- line
- timestamp
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final Comparator<Event> private static final Comparator<TestCaseEvent> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintprivate static inteventOrder(Event o) private static intfindInFixedOrder(Class<? extends Event> o) private static inttestCaseEvents(Event a, Event b) private static intprivate static URIMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.util.Comparator
equals, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
-
Field Details
-
eventOrder
-
testCaseOrder
-
fixedOrder
-
-
Constructor Details
-
CanonicalEventOrder
CanonicalEventOrder()
-
-
Method Details
-
compare
- Specified by:
comparein interfaceComparator<Event>
-
testCaseEvents
-
testCaseLine
-
testCaseUri
-
eventOrder
-
findInFixedOrder
-