Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
fslev committed Oct 11, 2022
1 parent 957ff84 commit a7261f1
Showing 1 changed file with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package io.json.compare.matcher;

import io.json.compare.JSONCompare;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.Test;

public class JSONArrayCompareTests {
Expand All @@ -19,6 +20,14 @@ public void compareEmptyArrays_negative() {
JSONCompare.assertNotMatches(expected, actual);
}

@Test
public void compareEmptyArrays_negative1() {
String expected = "[{}]";
String actual = "[]";
Assertions.assertThrows(AssertionError.class, () -> JSONCompare.assertMatches(expected, actual));
JSONCompare.assertNotMatches(expected, actual);
}

@Test
public void compareArraysWithDuplicatedElements() {
String expected = "[2,2,4,4,4]";
Expand Down

0 comments on commit a7261f1

Please sign in to comment.