From 167efb4fa065d3eb1b31699debc89498d04188d8 Mon Sep 17 00:00:00 2001 From: Steve Hanson Date: Wed, 3 Feb 2021 08:34:10 +0000 Subject: [PATCH] work around issue 1089 --- bin/unittestschema/address.json | Bin 3157 -> 3157 bytes test/unittest/schematest.cpp | 8 ++++---- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/bin/unittestschema/address.json b/bin/unittestschema/address.json index 007d971dafa038c6675eeca46fadfb5329bdafba..c3cf6426131c578fa9df93159f1153f0e749d7d7 100644 GIT binary patch delta 16 YcmcaAaaCf&3NB_tJ%i1wxmGa(05>HC;s5{u delta 16 YcmcaAaaCf&3NB^?J;TkbxmGa(05>BA;s5{u diff --git a/test/unittest/schematest.cpp b/test/unittest/schematest.cpp index 7f1b43e..ad19cd9 100644 --- a/test/unittest/schematest.cpp +++ b/test/unittest/schematest.cpp @@ -2293,7 +2293,7 @@ TEST(SchemaValidator, ContinueOnErrors) { VALIDATE(s, "{\"version\": 1.0, \"address\": {\"number\": 24, \"street1\": \"The Woodlands\", \"street3\": \"Ham\", \"city\": \"Romsey\", \"area\": \"Kent\", \"country\": \"UK\", \"postcode\": \"SO51 0GP\"}, \"phones\": [\"0111-222333\", \"0777-666888\"], \"names\": [\"Fred\", \"Bloggs\"]}", true); INVALIDATE_(s, "{\"version\": 1.01, \"address\": {\"number\": 0, \"street2\": false, \"street3\": \"Ham\", \"city\": \"RomseyTownFC\", \"area\": \"BC\", \"country\": \"USA\", \"postcode\": \"999ABC\"}, \"phones\": [], \"planet\": \"Earth\", \"extra\": {\"S_xxx\": 123}}", "#", "errors", "#", "{ \"multipleOf\": {" - " \"errorCode\": 1, \"instanceRef\": \"#/version\", \"schemaRef\": \"#/definitions/decimal_type\", \"expected\": 0.1, \"actual\": 1.01" + " \"errorCode\": 1, \"instanceRef\": \"#/version\", \"schemaRef\": \"#/definitions/decimal_type\", \"expected\": 1.0, \"actual\": 1.01" " }," " \"minimum\": {" " \"errorCode\": 5, \"instanceRef\": \"#/address/number\", \"schemaRef\": \"#/definitions/positiveInt_type\", \"expected\": 0, \"actual\": 0, \"exclusiveMinimum\": true" @@ -2390,7 +2390,7 @@ TEST(SchemaValidator, ContinueOnErrors_OneOf) { "{ \"oneOf\": {" " \"errors\": [{" " \"multipleOf\": {" - " \"errorCode\": 1, \"instanceRef\": \"#/version\", \"schemaRef\": \"http://localhost:1234/address.json#/definitions/decimal_type\", \"expected\": 0.1, \"actual\": 1.01" + " \"errorCode\": 1, \"instanceRef\": \"#/version\", \"schemaRef\": \"http://localhost:1234/address.json#/definitions/decimal_type\", \"expected\": 1.0, \"actual\": 1.01" " }" " }]," " \"errorCode\": 21, \"instanceRef\": \"#\", \"schemaRef\": \"#\"" @@ -2416,7 +2416,7 @@ TEST(SchemaValidator, ContinueOnErrors_AllOf) { "{ \"allOf\": {" " \"errors\": [{" " \"multipleOf\": {" - " \"errorCode\": 1, \"instanceRef\": \"#/version\", \"schemaRef\": \"http://localhost:1234/address.json#/definitions/decimal_type\", \"expected\": 0.1, \"actual\": 1.01" + " \"errorCode\": 1, \"instanceRef\": \"#/version\", \"schemaRef\": \"http://localhost:1234/address.json#/definitions/decimal_type\", \"expected\": 1.0, \"actual\": 1.01" " }" " }]," " \"errorCode\": 23, \"instanceRef\": \"#\", \"schemaRef\": \"#\"" @@ -2442,7 +2442,7 @@ TEST(SchemaValidator, ContinueOnErrors_AnyOf) { "{ \"anyOf\": {" " \"errors\": [{" " \"multipleOf\": {" - " \"errorCode\": 1, \"instanceRef\": \"#/version\", \"schemaRef\": \"http://localhost:1234/address.json#/definitions/decimal_type\", \"expected\": 0.1, \"actual\": 1.01" + " \"errorCode\": 1, \"instanceRef\": \"#/version\", \"schemaRef\": \"http://localhost:1234/address.json#/definitions/decimal_type\", \"expected\": 1.0, \"actual\": 1.01" " }" " }]," " \"errorCode\": 24, \"instanceRef\": \"#\", \"schemaRef\": \"#\""