Fighting flakey tests

This commit is contained in:
Marcin Grzejszczak
2017-11-17 12:02:05 +01:00
parent 85517c6670
commit 2ecd77d151
4 changed files with 12 additions and 23 deletions

View File

@@ -113,7 +113,8 @@ public class MessagingApplicationTests extends AbstractIntegrationTest {
.collect(Collectors.joining("\n")) + "\n]");
then(this.integrationTestSpanCollector.hashedSpans
.stream()
.filter(span -> !span.traceId().equals(traceIdHex))
.filter(span ->
org.springframework.cloud.sleuth.Span.hexToId(span.traceId()) != traceId)
.collect(Collectors.toList()))
.describedAs("All spans have same trace id [" + traceIdHex + "]")
.isEmpty();