-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #33 from smartystreets/iac-v2
support iac-v2
- Loading branch information
Showing
13 changed files
with
115 additions
and
110 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
import XCTest | ||
@testable import SmartyStreets | ||
|
||
class URLPrefixSenderTests: XCTestCase { | ||
|
||
var urlPrefixSender:URLPrefixSender! | ||
var inner:MockSender! | ||
var error:NSError! | ||
|
||
override func setUp() { | ||
super.setUp() | ||
self.inner = MockSender(response: nil) | ||
self.urlPrefixSender = URLPrefixSender(urlPrefix: "http://mysite.com/lookup", inner: self.inner as Any) | ||
} | ||
|
||
override func tearDown() { | ||
super.tearDown() | ||
self.urlPrefixSender = nil | ||
self.error = nil | ||
self.inner = nil | ||
} | ||
|
||
func testRequestURLPresent() { | ||
let request:SmartyRequest = SmartyRequest() | ||
request.urlPrefix = "/jimbo" | ||
|
||
_ = self.urlPrefixSender.sendRequest(request: request, error: &self.error) | ||
|
||
XCTAssertEqual(request.urlPrefix, "http://mysite.com/lookup/jimbo") | ||
|
||
} | ||
|
||
func testRequestURLNotPresent() { | ||
let request:SmartyRequest = SmartyRequest() | ||
|
||
_ = self.urlPrefixSender.sendRequest(request: request, error: &self.error) | ||
|
||
XCTAssertEqual(request.urlPrefix, "http://mysite.com/lookup") | ||
} | ||
|
||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.