-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Separate test-suite for URLProtocol #1115
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
6b091a4
to
69db9d9
Compare
Can we reduce the amount of code duplication by having |
69db9d9
to
53d9917
Compare
@ianpartridge Yeah, I have moved the server related code to HTTPServer file and have URLSession and URLProtocol tests inherit from there. Please have a look. |
TestFoundation/HTTPServer.swift
Outdated
@@ -394,3 +396,39 @@ public class ServerSemaphore { | |||
dispatchSemaphore.signal() | |||
} | |||
} | |||
|
|||
class ServerSetUp: XCTestCase { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we rename this to something like LoopbackServerTest
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed, ServerSetUp
is a poor name.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
waitForExpectations(timeout: 12) | ||
} | ||
|
||
func test_protocols() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we please rename this to something like test_multipleCustomProtocols
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, I have renamed it.
53d9917
to
8e8c708
Compare
@pushkarnk Renaming is done. Thanks for the review! |
@swift-ci please test and merge |
No description provided.