Skip to content

Commit 69953fc

Browse files
authored
Merge pull request #5505 from alphagov/bump-govuk-schemas
[PP-7588] Fix compatibility with content schemas
2 parents ecf3734 + 4ebc579 commit 69953fc

2 files changed

Lines changed: 12 additions & 4 deletions

File tree

Gemfile.lock

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ GEM
8181
autoprefixer-rails (10.4.21.0)
8282
execjs (~> 2)
8383
base64 (0.3.0)
84-
bigdecimal (4.1.1)
84+
bigdecimal (4.1.2)
8585
builder (3.3.0)
8686
byebug (13.0.0)
8787
reline (>= 0.6.0)
@@ -215,7 +215,7 @@ GEM
215215
rouge
216216
sprockets (>= 3)
217217
sprockets-rails
218-
govuk_schemas (6.3.0)
218+
govuk_schemas (6.3.1)
219219
json-schema (>= 2.8, < 6.3)
220220
govuk_tech_docs (5.2.2)
221221
autoprefixer-rails (~> 10.2)
@@ -780,6 +780,7 @@ PLATFORMS
780780
aarch64-linux
781781
arm64-darwin-23
782782
arm64-darwin-24
783+
arm64-darwin-25
783784
x86_64-darwin-23
784785
x86_64-linux
785786

spec/app/content_schema_spec.rb

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,11 @@
1616
schema = ContentSchema.new("generic").frontend_schema
1717

1818
expect(schema.properties["base_path"]["$ref"]).to eql(nil)
19-
expect(schema.properties["base_path"]["type"]).to eql("string")
19+
20+
expect(schema
21+
.properties
22+
.dig("base_path", "allOf")
23+
.map { _1["type"] }).to eql(%w[string string])
2024
end
2125
end
2226

@@ -37,7 +41,10 @@
3741
schema = ContentSchema.new("generic").publisher_content_schema
3842

3943
expect(schema.properties["base_path"]["$ref"]).to eql(nil)
40-
expect(schema.properties["base_path"]["type"]).to eql("string")
44+
expect(schema
45+
.properties
46+
.dig("base_path", "allOf")
47+
.map { _1["type"] }).to eql(%w[string string])
4148
end
4249
end
4350

0 commit comments

Comments
 (0)