webstub 1.1.5 → 1.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.gitignore +2 -0
- data/.travis.yml +1 -0
- data/lib/webstub/protocol.rb +4 -0
- data/lib/webstub/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: c9601adc5710e669132d18e14cbaf521c3c42ef0
|
|
4
|
+
data.tar.gz: fc62f6f87eff05c832b8fb114d6f82d35f07bbe7
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 26b4dc062c19d72ffbe096b3e11c087a4af5563cd922155744beaf16c24132f3c61731ef0422e0f6be292377c164c9ad686439eb0bba91970b80d0f2d592a53d
|
|
7
|
+
data.tar.gz: 68d512c58deacf1c5994dfd131e5b8d3bb293cb3a61feae101f8f8304a3b3c04c073610045adeb6620d74ca97a0f90598f676928594d8ca7e9e92a528cbcb3de
|
data/.gitignore
CHANGED
data/.travis.yml
CHANGED
data/lib/webstub/protocol.rb
CHANGED
|
@@ -58,6 +58,10 @@ module WebStub
|
|
|
58
58
|
|
|
59
59
|
if @stub.redirects?
|
|
60
60
|
url = NSURL.URLWithString(@stub.response_headers["Location"])
|
|
61
|
+
if request.URL == url
|
|
62
|
+
# Can't redirect to same URL. Since iOS 10, it will cause a crash.
|
|
63
|
+
return
|
|
64
|
+
end
|
|
61
65
|
redirect_request = NSURLRequest.requestWithURL(url)
|
|
62
66
|
|
|
63
67
|
client.URLProtocol(self, wasRedirectedToRequest: redirect_request, redirectResponse: response)
|
data/lib/webstub/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: webstub
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.1.
|
|
4
|
+
version: 1.1.6
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Matt Green
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date:
|
|
11
|
+
date: 2016-09-26 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: rake
|
|
@@ -94,7 +94,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
94
94
|
version: '0'
|
|
95
95
|
requirements: []
|
|
96
96
|
rubyforge_project:
|
|
97
|
-
rubygems_version: 2.
|
|
97
|
+
rubygems_version: 2.5.1
|
|
98
98
|
signing_key:
|
|
99
99
|
specification_version: 4
|
|
100
100
|
summary: Easily stub out HTTP responses in RubyMotion specs
|