Skip to content

Commit 1d6fc0c

Browse files
committed
Fix swift + apple tests
1 parent 321c9f4 commit 1d6fc0c

File tree

2 files changed

+14
-10
lines changed

2 files changed

+14
-10
lines changed

tests/languages/apple/Tests.swift

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -59,19 +59,19 @@ class Tests: XCTestCase {
5959

6060

6161
// Bar Tests
62-
mock = try await bar.get(xrequired: "string", xdefault: 123, z: ["string in array"])
62+
mock = try await bar.get(required: "string", default: 123, z: ["string in array"])
6363
print(mock.result)
6464

65-
mock = try await bar.post(xrequired: "string", xdefault: 123, z: ["string in array"])
65+
mock = try await bar.post(required: "string", default: 123, z: ["string in array"])
6666
print(mock.result)
6767

68-
mock = try await bar.put(xrequired: "string", xdefault: 123, z: ["string in array"])
68+
mock = try await bar.put(required: "string", default: 123, z: ["string in array"])
6969
print(mock.result)
7070

71-
mock = try await bar.patch(xrequired: "string", xdefault: 123, z: ["string in array"])
71+
mock = try await bar.patch(required: "string", default: 123, z: ["string in array"])
7272
print(mock.result)
7373

74-
mock = try await bar.delete(xrequired: "string", xdefault: 123, z: ["string in array"])
74+
mock = try await bar.delete(required: "string", default: 123, z: ["string in array"])
7575
print(mock.result)
7676

7777

tests/languages/swift/Tests.swift

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ class Tests: XCTestCase {
1919
}
2020

2121
func test() async throws {
22+
do {
2223
let client = Client()
2324
.setProject("console")
2425
.addHeader(key: "Origin", value: "http://localhost")
@@ -48,19 +49,19 @@ class Tests: XCTestCase {
4849

4950

5051
// Bar Tests
51-
mock = try await bar.get(xrequired: "string", xdefault: 123, z: ["string in array"])
52+
mock = try await bar.get(required: "string", default: 123, z: ["string in array"])
5253
print(mock.result)
5354

54-
mock = try await bar.post(xrequired: "string", xdefault: 123, z: ["string in array"])
55+
mock = try await bar.post(required: "string", default: 123, z: ["string in array"])
5556
print(mock.result)
5657

57-
mock = try await bar.put(xrequired: "string", xdefault: 123, z: ["string in array"])
58+
mock = try await bar.put(required: "string", default: 123, z: ["string in array"])
5859
print(mock.result)
5960

60-
mock = try await bar.patch(xrequired: "string", xdefault: 123, z: ["string in array"])
61+
mock = try await bar.patch(required: "string", default: 123, z: ["string in array"])
6162
print(mock.result)
6263

63-
mock = try await bar.delete(xrequired: "string", xdefault: 123, z: ["string in array"])
64+
mock = try await bar.delete(required: "string", default: 123, z: ["string in array"])
6465
print(mock.result)
6566

6667

@@ -167,5 +168,8 @@ class Tests: XCTestCase {
167168

168169
mock = try await general.headers()
169170
print(mock.result)
171+
} catch {
172+
print(error.localizedDescription)
173+
}
170174
}
171175
}

0 commit comments

Comments
 (0)