This is an automated email from the ASF dual-hosted git repository.
cschneider pushed a commit to branch master
in repository
https://gitbox.apache.org/repos/asf/sling-org-apache-sling-distribution-journal-messages.git
The following commit(s) were added to refs/heads/master by this push:
new 4ab6852 SLING-10066 - Fix incorrect usage of expected and actual in
test
4ab6852 is described below
commit 4ab68524fc89f471ee8fbc9bffd71cdec98a4dad
Author: Christian Schneider <[email protected]>
AuthorDate: Mon Mar 15 09:41:48 2021 +0100
SLING-10066 - Fix incorrect usage of expected and actual in test
---
.../sling/distribution/journal/messages/PackageMessageTest.java | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git
a/src/test/java/org/apache/sling/distribution/journal/messages/PackageMessageTest.java
b/src/test/java/org/apache/sling/distribution/journal/messages/PackageMessageTest.java
index 2ee58b4..493c09b 100644
---
a/src/test/java/org/apache/sling/distribution/journal/messages/PackageMessageTest.java
+++
b/src/test/java/org/apache/sling/distribution/journal/messages/PackageMessageTest.java
@@ -36,6 +36,7 @@ import java.util.Collections;
import java.util.List;
import java.util.stream.Collectors;
+import org.junit.Assert;
import org.junit.Test;
import com.fasterxml.jackson.core.JsonGenerationException;
@@ -75,19 +76,19 @@ public class PackageMessageTest {
@Test
public void testAbbreviateEmptyPaths() {
List<String> empty = Collections.emptyList();
- assertEquals(abbreviate(empty), empty.toString());
+ assertThat(abbreviate(empty), equalTo(empty.toString()));
}
@Test
public void testAbbreviateOnePaths() {
List<String> one = Collections.singletonList("/a/path");
- assertEquals(abbreviate(one), one.toString());
+ assertThat(abbreviate(one), equalTo(one.toString()));
}
@Test
public void testAbbreviateManyPaths() {
List<String> one = Arrays.asList("/a/path", "/another/one",
"/yet/another/one");
- assertEquals(abbreviate(one), "[/a/path, ... 2 more]");
+ assertThat(abbreviate(one), equalTo("[/a/path, ... 2 more]"));
}
}