[#89] Initial approach to the integration tests

- Fixed the tests
- Updated surefire
- Added integration tests (for the moment ignored)
- Fixed wrong surefire setup
This commit is contained in:
Marcin Grzejszczak
2016-01-08 19:08:34 +01:00
parent 7c54ad9e66
commit 9a8dc17d8c
29 changed files with 661 additions and 138 deletions

View File

@@ -19,6 +19,9 @@ package org.springframework.cloud.sleuth.zipkin.stream;
import io.zipkin.BinaryAnnotation;
import io.zipkin.Endpoint;
import java.util.Collections;
import java.util.Comparator;
import java.util.Objects;
import org.junit.Test;
import org.springframework.cloud.sleuth.MilliSpan;
import org.springframework.cloud.sleuth.stream.Host;
@@ -70,8 +73,9 @@ public class ZipkinMessageListenerTests {
public void spanWithoutAnnotationsLogsComponent() {
io.zipkin.Span result = ZipkinMessageListener.convert(span, host);
assertThat(result.binaryAnnotations)
.containsOnly(BinaryAnnotation.create("lc", span.getProcessId(), endpoint));
assertThat(result.binaryAnnotations).hasSize(1);
assertThat(result.binaryAnnotations.get(0)).isEqualToComparingFieldByField(
BinaryAnnotation.create("lc", span.getProcessId().toLowerCase(), endpoint));
}
// TODO: "unknown" bc process id, documented as not nullable, is null in some tests.