Skip to content

Commit 9b19708

Browse files
committed
Port repository tests
1 parent f57c1a1 commit 9b19708

File tree

3 files changed

+918
-22
lines changed

3 files changed

+918
-22
lines changed

schema/v1/no_index.schema.json

Lines changed: 23 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -7,23 +7,11 @@
77
"properties": {
88
"file": {
99
"description": "A list of relative paths to files. Paths **must be** specified with unix conventions.",
10-
"type": "array",
11-
"minItems": 1,
12-
"items": {
13-
"type": "string",
14-
"description": "Relative path in unix convention to a file to ignore.",
15-
"minLength": 1
16-
}
10+
"$ref": "#/$defs/fileList"
1711
},
1812
"directory": {
1913
"description": "A list of relative paths to directories. Paths **must be** specified with unix conventions.",
20-
"type": "array",
21-
"minItems": 1,
22-
"items": {
23-
"type": "string",
24-
"description": "Relative path in unix convention to a directory to ignore.",
25-
"minLength": 1
26-
}
14+
"$ref": "#/$defs/fileList"
2715
}
2816
},
2917
"anyOf": [{ "required": ["file"] }, { "required": ["directory"] }],
@@ -38,5 +26,25 @@
3826
"file": ["src/file.sql"],
3927
"directory": ["src/private"]
4028
}
41-
]
29+
],
30+
"$defs": {
31+
"fileList": {
32+
"oneOf": [
33+
{
34+
"type": "array",
35+
"minItems": 1,
36+
"items": {
37+
"type": "string",
38+
"description": "Relative path in unix convention to a file to ignore.",
39+
"minLength": 1
40+
}
41+
},
42+
{
43+
"type": "string",
44+
"description": "Relative path in unix convention to a file to ignore.",
45+
"minLength": 1
46+
}
47+
]
48+
}
49+
}
4250
}

schema/v1/repository.schema.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,8 @@
1717
},
1818
"type": {
1919
"type": "string",
20-
"description": "a lowercase string indicating the VCS used."
20+
"pattern": "^\\p{lower}*$",
21+
"description": "A lowercase string indicating the VCS used."
2122
}
2223
},
2324
"anyOf": [{ "required": ["url", "type"] }, { "required": ["web"] }],

0 commit comments

Comments
 (0)