Skip to content

Commit b01f3c5

Browse files
committed
Fixed failing test cases
1 parent aaf391b commit b01f3c5

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

document-store/src/test/java/org/hypertrace/core/documentstore/expression/impl/JsonArrayIdentifierExpressionTest.java

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,9 @@ void testOfWithEmptyPathElementsThrowsException() {
5555
assertThrows(
5656
IllegalArgumentException.class, () -> JsonArrayIdentifierExpression.of("attributes"));
5757

58-
assertEquals("JSON path cannot be null or empty for array field", exception.getMessage());
58+
assertEquals(
59+
"JSON path cannot be null or empty. Use of(columnName, path...) instead.",
60+
exception.getMessage());
5961
}
6062

6163
@Test
@@ -65,7 +67,7 @@ void testOfWithNullListThrowsException() {
6567
IllegalArgumentException.class,
6668
() -> JsonArrayIdentifierExpression.of("attributes", (List<String>) null));
6769

68-
assertEquals("JSON path cannot be null or empty", exception.getMessage());
70+
assertEquals("JSON path cannot be null or empty for array field", exception.getMessage());
6971
}
7072

7173
@Test
@@ -75,7 +77,7 @@ void testOfWithEmptyListThrowsException() {
7577
IllegalArgumentException.class,
7678
() -> JsonArrayIdentifierExpression.of("attributes", Collections.emptyList()));
7779

78-
assertEquals("JSON path cannot be null or empty", exception.getMessage());
80+
assertEquals("JSON path cannot be null or empty for array field", exception.getMessage());
7981
}
8082

8183
@Test

0 commit comments

Comments
 (0)