Skip to content

Commit 32b4154

Browse files
Update minimum version of OpenAPIKit to 3.1.2 (#439)
### Motivation This picks up a bug fix with inferred properties. While Swift package resolution should pick this up for adopters automatically, we want to go into 1.0 with the minimum version of the dependency bumped to one that includes the fix. ### Modifications Update minimum version of OpenAPIKit to 3.1.2 ### Result Requires newer OpenAPIKit with fix. ### Test Plan CI.
1 parent e6ea909 commit 32b4154

File tree

2 files changed

+11
-5
lines changed

2 files changed

+11
-5
lines changed

Package.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ let package = Package(
5151
.package(url: "https://github.com/apple/swift-algorithms", from: "1.0.0"),
5252

5353
// Read OpenAPI documents
54-
.package(url: "https://github.com/mattpolzin/OpenAPIKit.git", from: "3.1.0"),
54+
.package(url: "https://github.com/mattpolzin/OpenAPIKit.git", from: "3.1.2"),
5555
.package(url: "https://github.com/jpsim/Yams.git", "4.0.0"..<"6.0.0"),
5656

5757
// CLI Tool

Tests/OpenAPIGeneratorReferenceTests/CompatabilityTest.swift

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,8 @@ final class CompatibilityTest: XCTestCase {
5858
"https://raw.githubusercontent.com/box/box-openapi/5955d651f0cd273c0968e3855c1d873c7ae3523e/openapi.json",
5959
license: .apache,
6060
expectedDiagnostics: [
61-
"Multipart request bodies must always be required, but found an optional one - skipping. Mark as `required: true` to get this body generated."
61+
"Multipart request bodies must always be required, but found an optional one - skipping. Mark as `required: true` to get this body generated.",
62+
"A property name only appears in the required list, but not in the properties map - this is likely a typo; skipping this property.",
6263
],
6364
skipBuild: compatibilityTestSkipBuild
6465
)
@@ -98,7 +99,9 @@ final class CompatibilityTest: XCTestCase {
9899
try await _test(
99100
"https://raw.githubusercontent.com/github/rest-api-description/13c873cb3b15ffd5bcd88c6d6270a963ef4518f6/descriptions/api.github.com/api.github.com.yaml",
100101
license: .mit,
101-
expectedDiagnostics: [],
102+
expectedDiagnostics: [
103+
"A property name only appears in the required list, but not in the properties map - this is likely a typo; skipping this property."
104+
],
102105
skipBuild: true
103106
)
104107
}
@@ -108,7 +111,8 @@ final class CompatibilityTest: XCTestCase {
108111
"https://raw.githubusercontent.com/github/rest-api-description/13c873cb3b15ffd5bcd88c6d6270a963ef4518f6/descriptions/ghes-3.5/ghes-3.5.yaml",
109112
license: .mit,
110113
expectedDiagnostics: [
111-
"Multipart request bodies must always be required, but found an optional one - skipping. Mark as `required: true` to get this body generated."
114+
"Multipart request bodies must always be required, but found an optional one - skipping. Mark as `required: true` to get this body generated.",
115+
"A property name only appears in the required list, but not in the properties map - this is likely a typo; skipping this property.",
112116
],
113117
skipBuild: true
114118
)
@@ -127,7 +131,9 @@ final class CompatibilityTest: XCTestCase {
127131
try await _test(
128132
"https://raw.githubusercontent.com/Netflix/consoleme/774420462b0190b1bfa78aa73d39e20044f52db9/swagger.yaml",
129133
license: .apache,
130-
expectedDiagnostics: [],
134+
expectedDiagnostics: [
135+
"A property name only appears in the required list, but not in the properties map - this is likely a typo; skipping this property."
136+
],
131137
skipBuild: compatibilityTestSkipBuild
132138
)
133139
}

0 commit comments

Comments
 (0)