Skip to content

Commit

Permalink
released 1.8.9
Browse files Browse the repository at this point in the history
  • Loading branch information
MarioRuiz committed Mar 18, 2021
1 parent 4978fcc commit 0f19573
Show file tree
Hide file tree
Showing 10 changed files with 18 additions and 13 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ Gemfile.lock
/doc/
nice_http_stats*.*
nice_http_tmp_stats*.*
/spec/examples.txt

# Used by dotenv library to load environment variables.
# .env
Expand Down
1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ rvm:
- 2.4
- 2.5
- 2.6
- 3.0
- ruby-head
branches:
except:
Expand Down
1 change: 1 addition & 0 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,4 +36,5 @@ environment:
- ruby_version: 24-x64
- ruby_version: 25-x64
- ruby_version: 26-x64
- ruby_version: 27-x64

2 changes: 1 addition & 1 deletion nice_http.gemspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Gem::Specification.new do |s|
s.name = 'nice_http'
s.version = '1.8.8'
s.version = '1.8.9'
s.summary = "NiceHttp -- simplest library for accessing and testing HTTP and REST resources. Get http logs and statistics automatically. Use hashes on your requests. Access JSON even easier."
s.description = "NiceHttp -- simplest library for accessing and testing HTTP and REST resources. Get http logs and statistics automatically. Use hashes on your requests. Access JSON even easier."
s.authors = ["Mario Ruiz"]
Expand Down
4 changes: 2 additions & 2 deletions spec/nice_http/delete_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -43,15 +43,15 @@
end

it 'doesn\'t redirect when auto_redirect is false and http code is 30x' do
server = "http://examplesinatra--tcblues.repl.co/"
server = "https://examplesinatra--tcblues.repl.co/"
http = NiceHttp.new(server)
http.auto_redirect = false
req = {
path: "/exampleRedirect",
data: {example: "example"},
}
resp = http.delete(req)
expect(resp.code).to eq 303
expect(resp.code).to be_in('300'..'399')
end

it "detects wrong json when supplying wrong mock_response data" do
Expand Down
4 changes: 2 additions & 2 deletions spec/nice_http/head_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -53,14 +53,14 @@
end

it 'doesn\'t redirect when auto_redirect is false and http code is 30x' do
server = "http://examplesinatra--tcblues.repl.co/"
server = "https://examplesinatra--tcblues.repl.co/"
http = NiceHttp.new(server)
http.auto_redirect = false
req = {
path: "/exampleRedirect",
data: {example: "example"},
}
resp = http.head(req)
expect(resp.code).to eq 303
expect(resp.code.to_i).to be_in(300..399)
end
end
6 changes: 3 additions & 3 deletions spec/nice_http/patch_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@
end

it "redirects when auto_redirect is true and http code is 30x" do
server = "http://examplesinatra--tcblues.repl.co/"
server = "https://examplesinatra--tcblues.repl.co/"
http = NiceHttp.new(server)
http.auto_redirect = true
req = {
Expand All @@ -82,15 +82,15 @@
end

it 'doesn\'t redirect when auto_redirect is false and http code is 30x' do
server = "http://examplesinatra--tcblues.repl.co/"
server = "https://examplesinatra--tcblues.repl.co/"
http = NiceHttp.new(server)
http.auto_redirect = false
req = {
path: "/exampleRedirect",
data: {example: "example"},
}
resp = http.patch(req)
expect(resp.code).to eq 303
expect(resp.code).to be_in('300'..'399')
end

it "detects wrong json when supplying wrong mock_response data" do
Expand Down
6 changes: 3 additions & 3 deletions spec/nice_http/post_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@
end

it "redirects when auto_redirect is true and http code is 30x" do
server = "http://examplesinatra--tcblues.repl.co/"
server = "https://examplesinatra--tcblues.repl.co/"
http = NiceHttp.new(server)
http.auto_redirect = true
req = {
Expand All @@ -83,15 +83,15 @@
end

it 'doesn\'t redirect when auto_redirect is false and http code is 30x' do
server = "http://examplesinatra--tcblues.repl.co/"
server = "https://examplesinatra--tcblues.repl.co/"
http = NiceHttp.new(server)
http.auto_redirect = false
req = {
path: "/exampleRedirect",
data: {example: "example"},
}
resp = http.post(req)
expect(resp.code).to eq 303
expect(resp.code).to be_in('300'..'399')
end

it "accepts all kind of Content-Type" do
Expand Down
4 changes: 2 additions & 2 deletions spec/nice_http/put_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -82,15 +82,15 @@


it 'doesn\'t redirect when auto_redirect is false and http code is 30x' do
server = "http://examplesinatra--tcblues.repl.co/"
server = "https://examplesinatra--tcblues.repl.co/"
http = NiceHttp.new(server)
http.auto_redirect = false
req = {
path: "/exampleRedirect",
data: {example: "example"},
}
resp = http.put(req)
expect(resp.code).to eq 303
expect(resp.code).to be_in('300'..'399')
end

it "detects wrong json when supplying wrong mock_response data" do
Expand Down
2 changes: 2 additions & 0 deletions spec/spec_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@
expectations.include_chain_clauses_in_custom_matcher_descriptions = true
end

config.example_status_persistence_file_path = "spec/examples.txt"

# rspec-mocks config goes here. You can use an alternate test double
# library (such as bogus or mocha) by changing the `mock_with` option here.
config.mock_with :rspec do |mocks|
Expand Down

0 comments on commit 0f19573

Please sign in to comment.