This repository has been archived by the owner on Aug 25, 2024. It is now read-only.
forked from LangStream/langstream
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
3eb3cb1
commit 7df0a9b
Showing
4 changed files
with
38 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
24 changes: 24 additions & 0 deletions
24
...tream-k8s-deployer-core/src/test/java/ai/langstream/deployer/k8s/util/SpecDifferTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
package ai.langstream.deployer.k8s.util; | ||
|
||
import static org.junit.jupiter.api.Assertions.*; | ||
|
||
import java.util.Map; | ||
import org.junit.jupiter.api.Test; | ||
|
||
class SpecDifferTest { | ||
|
||
@Test | ||
void testJsonOrderAndNulls() throws Exception { | ||
String json1 = | ||
""" | ||
{ | ||
"c": 3, | ||
"a": 1, | ||
"b": null | ||
}"""; | ||
|
||
JSONComparator.Result result = SpecDiffer.generateDiff(json1, Map.of("a", 1, "c", 3)); | ||
SpecDiffer.logDetailedSpecDiff(result); | ||
assertTrue(result.areEquals()); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters