Skip to content

Commit fe2916c

Browse files
committed
Update tests
1 parent de159ef commit fe2916c

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

TestFoundation/TestNSHTTPCookie.swift

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -125,15 +125,15 @@ class TestNSHTTPCookie: XCTestCase {
125125
"Set-Cookie": "fr=anjd&232; Max-Age=7776000; path=/; domain=.example.com; secure; httponly",
126126
"header2":"value2",
127127
"header3":"value3"]
128-
let cookies = HTTPCookie.cookies(withResponseHeaderFields: header, forURL: URL(string: "http://example.com")!)
128+
let cookies = HTTPCookie.cookies(withResponseHeaderFields: header, for: URL(string: "http://example.com")!)
129129
XCTAssertEqual(cookies.count, 1)
130130
XCTAssertEqual(cookies[0].name, "fr")
131131
XCTAssertEqual(cookies[0].value, "anjd&232")
132132
}
133133

134134
func test_cookiesWithResponseHeader0cookies() {
135135
let header = ["header1":"value1", "header2":"value2", "header3":"value3"]
136-
let cookies = HTTPCookie.cookies(withResponseHeaderFields: header, forURL: URL(string: "http://example.com")!)
136+
let cookies = HTTPCookie.cookies(withResponseHeaderFields: header, for: URL(string: "http://example.com")!)
137137
XCTAssertEqual(cookies.count, 0)
138138
}
139139

@@ -142,7 +142,7 @@ class TestNSHTTPCookie: XCTestCase {
142142
"Set-Cookie": "fr=a&2@#; Max-Age=1186000; path=/; domain=.example.com; secure, xd=plm!@#;path=/;domain=.example2.com",
143143
"header2":"value2",
144144
"header3":"value3"]
145-
let cookies = HTTPCookie.cookies(withResponseHeaderFields: header, forURL: URL(string: "http://example.com")!)
145+
let cookies = HTTPCookie.cookies(withResponseHeaderFields: header, for: URL(string: "http://example.com")!)
146146
XCTAssertEqual(cookies.count, 2)
147147
XCTAssertTrue(cookies[0].isSecure)
148148
XCTAssertFalse(cookies[1].isSecure)
@@ -153,7 +153,7 @@ class TestNSHTTPCookie: XCTestCase {
153153
"Set-Cookie": "fr=anjd&232; expires=Wed, 21 Sep 2016 05:33:00 GMT; Max-Age=7776000; path=/; secure; httponly",
154154
"header2":"value2",
155155
"header3":"value3"]
156-
let cookies = HTTPCookie.cookies(withResponseHeaderFields: header, forURL: URL(string: "http://example.com")!)
156+
let cookies = HTTPCookie.cookies(withResponseHeaderFields: header, for: URL(string: "http://example.com")!)
157157
XCTAssertEqual(cookies[0].domain, "http://example.com")
158158
XCTAssertNotNil(cookies[0].expiresDate)
159159

@@ -173,7 +173,7 @@ class TestNSHTTPCookie: XCTestCase {
173173
"Set-Cookie": "fr=tx; expires=Wed, 21-Sep-2016 05:33:00 GMT; Max-Age=7776000; secure; httponly",
174174
"header2":"value2",
175175
"header3":"value3"]
176-
let cookies = HTTPCookie.cookies(withResponseHeaderFields: header, forURL: URL(string: "http://example.com")!)
176+
let cookies = HTTPCookie.cookies(withResponseHeaderFields: header, for: URL(string: "http://example.com")!)
177177
XCTAssertEqual(cookies[0].domain, "http://example.com")
178178
XCTAssertEqual(cookies[0].path, "/")
179179
}

0 commit comments

Comments
 (0)