From cbd48ea550904ec552fd0b31262835112cc9a277 Mon Sep 17 00:00:00 2001 From: Ethan Date: Thu, 18 Apr 2024 13:07:44 -0700 Subject: [PATCH] Simplify test of \a regex character to test directly against `pattern` schema --- tests/draft-next/optional/ecmascript-regex.json | 4 ++-- tests/draft2020-12/optional/ecmascript-regex.json | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/draft-next/optional/ecmascript-regex.json b/tests/draft-next/optional/ecmascript-regex.json index 27211450..c96d4e05 100644 --- a/tests/draft-next/optional/ecmascript-regex.json +++ b/tests/draft-next/optional/ecmascript-regex.json @@ -409,12 +409,12 @@ "description": "\\a is not an ECMA 262 control escape", "schema": { "$schema": "https://json-schema.org/draft/next/schema", - "$ref": "https://json-schema.org/draft/next/schema" + "format": "regex" }, "tests": [ { "description": "when used as a pattern", - "data": { "pattern": "\\a" }, + "data": "\\a", "valid": false } ] diff --git a/tests/draft2020-12/optional/ecmascript-regex.json b/tests/draft2020-12/optional/ecmascript-regex.json index 23b962e4..97649531 100644 --- a/tests/draft2020-12/optional/ecmascript-regex.json +++ b/tests/draft2020-12/optional/ecmascript-regex.json @@ -409,12 +409,12 @@ "description": "\\a is not an ECMA 262 control escape", "schema": { "$schema": "https://json-schema.org/draft/2020-12/schema", - "$ref": "https://json-schema.org/draft/2020-12/schema" + "format": "regex" }, "tests": [ { "description": "when used as a pattern", - "data": { "pattern": "\\a" }, + "data": "\\a", "valid": false } ]