@Issue("587")
@Issue("572")
@Test
void shouldSortByStartTimeAsc() {

    final Category category = new Category().setName("some");
    final TestResult first = new TestResult()
            .setName("first")
            .setStatus(Status.FAILED)
            .setTime(new Time().setStart(10L));
    first.addExtraBlock(CATEGORIES, singletonList(category));
    final TestResult second = new TestResult()
            .setName("second")
            .setStatus(Status.FAILED)
            .setTime(new Time().setStart(12L));
    second.addExtraBlock(CATEGORIES, singletonList(category));
    final TestResult timeless = new TestResult()
            .setName("timeless")
            .setStatus(Status.FAILED);
    timeless.addExtraBlock(CATEGORIES, singletonList(category));
    final Tree<TestResult> tree = CategoriesPlugin.getData(
            createSingleLaunchResults(second, first, timeless)
    );
    assertThat(tree.getChildren())
            .flatExtracting("children")
            .flatExtracting("children")
            .extracting("name")
            .containsExactly("timeless", "first", "second");
}