1[ 2 { 3 "description": "issue782 using ECMA-262", 4 "schema": { 5 "$schema": "https://json-schema.org/draft/2020-12/schema", 6 "patternProperties": { 7 "^x-": true, 8 "y-$": true, 9 "^z-$": true 10 }, 11 "unevaluatedProperties": false 12 }, 13 "tests": [ 14 { 15 "description": "regexes may be anchored to the start of the property name, 1", 16 "regex": "ecma-262", 17 "data": { "x-api-id": 3 }, 18 "valid": true 19 }, 20 { 21 "description": "regexes may be anchored to the start of the property name, 2", 22 "regex": "ecma-262", 23 "data": { "ax-api-id": 3 }, 24 "valid": false 25 }, 26 { 27 "description": "regexes may be anchored to the end of the property name, 1", 28 "regex": "ecma-262", 29 "data": { "api-id-y-": 3 }, 30 "valid": true 31 }, 32 { 33 "description": "regexes may be anchored to the end of the property name, 2", 34 "regex": "ecma-262", 35 "data": { "y-api-id": 3 }, 36 "valid": false 37 }, 38 { 39 "description": "regexes may be anchored to both ends of the property name, 1", 40 "regex": "ecma-262", 41 "data": { "z-": 3 }, 42 "valid": true 43 }, 44 { 45 "description": "regexes may be anchored to both ends of the property name, 2", 46 "regex": "ecma-262", 47 "data": { "az-api-id": 3 }, 48 "valid": false 49 } 50 ] 51 }, 52 { 53 "description": "issue782 using Java Pattern", 54 "schema": { 55 "$schema": "https://json-schema.org/draft/2020-12/schema", 56 "patternProperties": { 57 "^x-": true, 58 "y-$": true, 59 "^z-$": true 60 }, 61 "unevaluatedProperties": false 62 }, 63 "tests": [ 64 { 65 "description": "regexes may be anchored to the start of the property name, 1", 66 "regex": "jdk", 67 "data": { "x-api-id": 3 }, 68 "valid": true 69 }, 70 { 71 "description": "regexes may be anchored to the start of the property name, 2", 72 "regex": "jdk", 73 "data": { "ax-api-id": 3 }, 74 "valid": false 75 }, 76 { 77 "description": "regexes may be anchored to the end of the property name, 1", 78 "regex": "jdk", 79 "data": { "api-id-y-": 3 }, 80 "valid": true 81 }, 82 { 83 "description": "regexes may be anchored to the end of the property name, 2", 84 "regex": "jdk", 85 "data": { "y-api-id": 3 }, 86 "valid": false 87 }, 88 { 89 "description": "regexes may be anchored to both ends of the property name, 1", 90 "regex": "jdk", 91 "data": { "z-": 3 }, 92 "valid": true 93 }, 94 { 95 "description": "regexes may be anchored to both ends of the property name, 2", 96 "regex": "jdk", 97 "data": { "az-api-id": 3 }, 98 "valid": false 99 } 100 ] 101 } 102] 103