Add support for JSON assertions using JSON compare

This commit moves JSON content AssertJ support from Spring Boot.

See gh-21178

Co-authored-by: Brian Clozel <brian.clozel@broadcom.com>
This commit is contained in:
Stéphane Nicoll
2024-03-15 13:14:38 +01:00
parent 214a54dd6f
commit 97ebc43ea9
14 changed files with 1143 additions and 0 deletions

View File

@@ -0,0 +1,6 @@
{
"gnirps": [
"boot",
"framework"
]
}

View File

@@ -0,0 +1,4 @@
{
"name": "Spring",
"age": 123
}

View File

@@ -0,0 +1,6 @@
{
"spring": [
"framework",
"boot"
]
}

View File

@@ -0,0 +1,4 @@
{
"valuename": "spring",
"nullname": null
}

View File

@@ -0,0 +1,36 @@
{
"familyMembers": [
{
"name": "Homer"
},
{
"name": "Marge"
},
{
"name": "Bart"
},
{
"name": "Lisa"
},
{
"name": "Maggie"
}
],
"indexedFamilyMembers": {
"father": {
"name": "Homer"
},
"mother": {
"name": "Marge"
},
"son": {
"name": "Bart"
},
"daughter": {
"name": "Lisa"
},
"baby": {
"name": "Maggie"
}
}
}

View File

@@ -0,0 +1,6 @@
{
"spring": [
"boot",
"framework"
]
}

View File

@@ -0,0 +1,18 @@
{
"str": "foo",
"num": 5,
"pi": 3.1415926,
"bool": true,
"arr": [
42
],
"colorMap": {
"red": "rojo"
},
"whitespace": " ",
"emptyString": "",
"emptyArray": [
],
"emptyMap": {
}
}