From 9b752e9dc7847f4537cfb1479a21b478bb695795 Mon Sep 17 00:00:00 2001 From: Manjunath Davanam Date: Thu, 29 Aug 2024 10:54:06 +0530 Subject: [PATCH] #OBS-I180: Validator Enhancement Draft 12 Support - Updated the testcase fixtures --- .../org/sunbird/obsrv/preprocessor/fixture/EventFixtures.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pipeline/preprocessor/src/test/scala/org/sunbird/obsrv/preprocessor/fixture/EventFixtures.scala b/pipeline/preprocessor/src/test/scala/org/sunbird/obsrv/preprocessor/fixture/EventFixtures.scala index a9b910ce..2a8f630f 100644 --- a/pipeline/preprocessor/src/test/scala/org/sunbird/obsrv/preprocessor/fixture/EventFixtures.scala +++ b/pipeline/preprocessor/src/test/scala/org/sunbird/obsrv/preprocessor/fixture/EventFixtures.scala @@ -3,7 +3,7 @@ package org.sunbird.obsrv.preprocessor.fixture object EventFixtures { val VALID_SCHEMA = """{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"id":{"type":"string"},"vehicleCode":{"type":"string"},"date":{"type":"string"},"dealer":{"type":"object","properties":{"dealerCode":{"type":"string"},"locationId":{"type":"string"},"email":{"type":"string"},"phone":{"type":"string"}},"additionalProperties":false,"required":["dealerCode","locationId"]},"metrics":{"type":"object","properties":{"bookingsTaken":{"type":"integer"},"deliveriesPromised":{"type":"integer"},"deliveriesDone":{"type":"integer"}},"additionalProperties":false}},"additionalProperties":false,"required":["id","vehicleCode","date"]}""" - val INVALID_SCHEMA = """{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"array","items":"false"}""" + val INVALID_SCHEMA = """{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"array","items":"unknown"}""" val INVALID_SCHEMA_JSON = """{"$schema":"https://json-schema.org/draft/2020-12/schema","$id":"https://sunbird.obsrv.com/test.json","title":"Test Schema","description":"Test Schema","type":"object","properties":{"id":{"type":"string"},"vehicleCode":{"type":"string"},"date":{"type":"string"},"dealer":{"type":"object","properties":{"dealerCode":{"type":"string"},"locationId":{"type":"string"},"email":{"type":"string"},"phone":{"type":"string"}},"required":["dealerCode","locationId"]},"metrics":{"type":"object","properties":{"bookingsTaken":{"type":"number"},"deliveriesPromised":{"type":"number"},"deliveriesDone":{"type":"number"}}}},"required":["id","vehicleCode","date","dealer","metrics"}"""