Skip to content

Commit

Permalink
Only run test when Swift compiler < 5.9
Browse files Browse the repository at this point in the history
  • Loading branch information
Widcket committed Oct 24, 2023
1 parent 1b73795 commit 8618879
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Auth0Tests/RequestSpec.swift
Original file line number Diff line number Diff line change
Expand Up @@ -94,10 +94,12 @@ class RequestSpec: QuickSpec {
expect(body["foo"] as? String) == "bar"
}

#if swift(<5.9)
it("should not add the parameters as query parameters when the URL is malformed") {
let request = Request(url: URL(string: ":INVALID:")!, parameters: ["foo": "bar"])
let request = Request(url: URL(string: "//:invalid/url")!, parameters: ["foo": "bar"])
expect(request.request.url?.query).to(beNil())
}
#endif
}

context("headers") {
Expand Down

0 comments on commit 8618879

Please sign in to comment.