rest_baby 1.5.1 → 1.6.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.codeclimate.yml +39 -0
- data/.gitignore +3 -0
- data/.travis.yml +53 -3
- data/ChangeLog +6 -1
- data/Gemfile +10 -14
- data/README.md +10 -9
- data/Rakefile +38 -9
- data/config/config.reek +30 -0
- data/cucumber.yml +1 -0
- data/features/nil_body.feature +20 -0
- data/features/step_definitions/rest_client_steps.rb +22 -0
- data/lib/rest_baby.rb +8 -8
- data/lib/rest_baby/version.rb +1 -1
- data/rest_baby.gemspec +5 -5
- metadata +9 -66
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6b7b7443ba8576c50f5da518edd296251f8208c4
|
4
|
+
data.tar.gz: d9fdfd2befbe02da53f6006e1bf0750cad64b1ca
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 39ad7b000365d9faf3baaa84e9bc009af229b537bc51c0289a0ece75457daa9283afaa3f9a681f02537892c9ee5b062f12b04b2e61c38efa8e15ec88a5f15f07
|
7
|
+
data.tar.gz: b22c1f8da9daa64e11a4ad7dc98ec35545cd1aa019366fdbfc9e14817f07a3ceffb1aba0308a7f9ae993eb9d33d7dd41c046895dfea3474db1c55a1068c21649
|
data/.codeclimate.yml
CHANGED
@@ -1,6 +1,44 @@
|
|
1
1
|
engines:
|
2
2
|
rubocop:
|
3
3
|
enabled: true
|
4
|
+
# Configuration parameters: AllowURI, URISchemes.
|
5
|
+
Metrics/LineLength:
|
6
|
+
Max: 81
|
7
|
+
|
8
|
+
# Configuration parameters: CountComments.
|
9
|
+
Metrics/MethodLength:
|
10
|
+
Max: 14
|
11
|
+
|
12
|
+
# Configuration parameters: CountKeywordArgs.
|
13
|
+
Metrics/ParameterLists:
|
14
|
+
Max: 6
|
15
|
+
reek:
|
16
|
+
enabled: true
|
17
|
+
UtilityFunction:
|
18
|
+
exclude:
|
19
|
+
- RestBaby::Client#header_text
|
20
|
+
- RestBaby::Client#pretty_xml
|
21
|
+
ControlParameter:
|
22
|
+
exclude:
|
23
|
+
- RestBaby::Client#body_text
|
24
|
+
DuplicateMethodCall:
|
25
|
+
exclude:
|
26
|
+
- RestBaby::Client#print_request
|
27
|
+
DataClump:
|
28
|
+
exclude:
|
29
|
+
- RestBaby::Client
|
30
|
+
FeatureEnvy:
|
31
|
+
exclude:
|
32
|
+
- RestBaby::Client#print_request
|
33
|
+
InstanceVariableAssumption:
|
34
|
+
exclude:
|
35
|
+
- RestBaby::Client
|
36
|
+
TooManyInstanceVariables:
|
37
|
+
exclude:
|
38
|
+
- RestBaby::Client
|
39
|
+
TooManyStatements:
|
40
|
+
exclude:
|
41
|
+
- RestBaby::Client#send_request
|
4
42
|
ratings:
|
5
43
|
paths:
|
6
44
|
- lib/**
|
@@ -8,3 +46,4 @@ ratings:
|
|
8
46
|
exclude_paths:
|
9
47
|
- doc/**/*
|
10
48
|
- features/**/*
|
49
|
+
|
data/.gitignore
ADDED
data/.travis.yml
CHANGED
@@ -1,6 +1,56 @@
|
|
1
1
|
language: ruby
|
2
2
|
rvm:
|
3
3
|
- 2.0.0
|
4
|
-
- 2.1.
|
5
|
-
- 2.2.
|
6
|
-
-
|
4
|
+
- 2.1.10
|
5
|
+
- 2.2.5
|
6
|
+
- 2.3.1
|
7
|
+
- ruby-head
|
8
|
+
- jruby-19mode
|
9
|
+
- jruby-head
|
10
|
+
jdk:
|
11
|
+
- openjdk6
|
12
|
+
- openjdk7
|
13
|
+
- oraclejdk7
|
14
|
+
- oraclejdk8
|
15
|
+
matrix:
|
16
|
+
allow_failures:
|
17
|
+
- rvm: jruby-19mode
|
18
|
+
- rvm: ruby-head
|
19
|
+
- rvm: jruby-head
|
20
|
+
exclude:
|
21
|
+
- rvm: 2.0.0
|
22
|
+
jdk: openjdk6
|
23
|
+
- rvm: 2.0.0
|
24
|
+
jdk: openjdk7
|
25
|
+
- rvm: 2.0.0
|
26
|
+
jdk: oraclejdk7
|
27
|
+
- rvm: 2.1.10
|
28
|
+
jdk: openjdk6
|
29
|
+
- rvm: 2.1.10
|
30
|
+
jdk: openjdk7
|
31
|
+
- rvm: 2.1.10
|
32
|
+
jdk: oraclejdk7
|
33
|
+
- rvm: 2.2.5
|
34
|
+
jdk: openjdk6
|
35
|
+
- rvm: 2.2.5
|
36
|
+
jdk: openjdk7
|
37
|
+
- rvm: 2.2.5
|
38
|
+
jdk: oraclejdk7
|
39
|
+
- rvm: 2.3.1
|
40
|
+
jdk: openjdk6
|
41
|
+
- rvm: 2.3.1
|
42
|
+
jdk: openjdk7
|
43
|
+
- rvm: 2.3.1
|
44
|
+
jdk: oraclejdk7
|
45
|
+
- rvm: rbx-2
|
46
|
+
jdk: openjdk6
|
47
|
+
- rvm: rbx-2
|
48
|
+
jdk: openjdk7
|
49
|
+
- rvm: rbx-2
|
50
|
+
jdk: oraclejdk7
|
51
|
+
- rvm: ruby-head
|
52
|
+
jdk: openjdk6
|
53
|
+
- rvm: ruby-head
|
54
|
+
jdk: openjdk7
|
55
|
+
- rvm: ruby-head
|
56
|
+
jdk: oraclejdk7
|
data/ChangeLog
CHANGED
@@ -54,4 +54,9 @@
|
|
54
54
|
=== Version 1.5.1 / 2016-03-08
|
55
55
|
* Updated README.md
|
56
56
|
* Added more config files to provide better status feedback
|
57
|
-
|
57
|
+
=== Version 1.6 / 2016-10-18
|
58
|
+
* Updated supported versions list (removed 1.9 versions, rbx-2)
|
59
|
+
* Updated travis to test latest released versions of 2.0-2.3
|
60
|
+
* Updated README.md
|
61
|
+
* Updated reek ignore list
|
62
|
+
* Added "demo" mode profile to cucumber.yml
|
data/Gemfile
CHANGED
@@ -1,23 +1,19 @@
|
|
1
1
|
source 'https://rubygems.org'
|
2
2
|
|
3
|
-
|
4
|
-
gem 'nokogiri'
|
3
|
+
gemspec
|
5
4
|
|
5
|
+
version = RUBY_VERSION[0..2].split('.')[0..1].join('.').to_f
|
6
6
|
group :development do
|
7
|
-
gem 'bundler'
|
8
|
-
gem 'rake'
|
9
|
-
gem 'cucumber'
|
10
|
-
gem 'fig_newton'
|
11
|
-
gem 'rspec'
|
12
|
-
gem 'webmock'
|
13
|
-
gem 'coveralls'
|
14
|
-
gem 'simplecov'
|
15
7
|
gem 'rubocop'
|
16
|
-
if
|
17
|
-
|
18
|
-
|
8
|
+
if version > 2.0
|
9
|
+
gem 'reek'
|
10
|
+
end
|
11
|
+
end
|
12
|
+
|
13
|
+
group :documentation do
|
14
|
+
if not(ENV['JRUBY'] || RUBY_PLATFORM == 'java')
|
19
15
|
gem 'yard'
|
20
|
-
gem 'yard-cucumber'
|
16
|
+
gem 'yard-cucumber', git: 'https://github.com/burtlo/yard-cucumber'
|
21
17
|
gem 'redcarpet'
|
22
18
|
end
|
23
19
|
end
|
data/README.md
CHANGED
@@ -1,15 +1,16 @@
|
|
1
1
|
# rest_baby
|
2
2
|
|
3
|
-
Small rest client, supports ruby-2.0.0, ruby-2.1.0, ruby-2.2.0
|
3
|
+
Small rest client, supports ruby-2.0.0, ruby-2.1.0, and ruby-2.2.0. You can only run reek with ruby 2.1 or above. You *could* use jruby but some develop dependencies are not supported any longer, including coveralls and yard-cucumber.
|
4
4
|
|
5
5
|
Item | Status
|
6
6
|
--- | ---
|
7
7
|
Gem | [![Gem Version](https://badge.fury.io/rb/rest_baby.svg)](https://badge.fury.io/rb/rest_baby )
|
8
8
|
Dependencies | [![Dependency Status](https://gemnasium.com/dmcnulla/rest_baby.svg)](https://gemnasium.com/dmcnulla/rest_baby)
|
9
|
-
Build | [![Build Status](https://travis-ci.org/dmcnulla/rest_baby.svg?branch=master)](https://travis-ci.org/dmcnulla/rest_baby)
|
9
|
+
Build/Test | [![Build Status](https://travis-ci.org/dmcnulla/rest_baby.svg?branch=master)](https://travis-ci.org/dmcnulla/rest_baby)
|
10
10
|
Coverage | [![Coverage Status](https://coveralls.io/repos/dmcnulla/rest_baby/badge.svg?branch=v1_5&service=github)](https://coveralls.io/github/dmcnulla/rest_baby?branch=v1_5)
|
11
11
|
Code Analysis | [![Code Climate](https://codeclimate.com/github/dmcnulla/rest_baby/badges/gpa.svg)](https://codeclimate.com/github/dmcnulla/rest_baby)
|
12
12
|
Docs | [![Inline docs](http://inch-ci.org/github/dmcnulla/rest_baby.svg?branch=master)](http://inch-ci.org/github/dmcnulla/rest_baby)
|
13
|
+
codeship | [ ![Codeship Status for dmcnulla/rest_baby](https://codeship.com/projects/6002d4e0-efc4-0133-4e00-7aa0b68b0e4b/status?branch=master)](https://codeship.com/projects/149095)
|
13
14
|
|
14
15
|
## Purpose
|
15
16
|
|
@@ -35,18 +36,18 @@ Or install it yourself as:
|
|
35
36
|
client = RestBaby::Client.new('http://gis.srh.noaa.gov/arcgis/rest/services/System')
|
36
37
|
# get(HEADERS, PATH, PARAMETERS)
|
37
38
|
# returns http response, usually the body is what is wanted.
|
38
|
-
message = JSON.parse(client.get( { 'Accept' => 'application/json' },
|
39
|
-
'/ReportingTools/GPServer/info/iteminfo',
|
39
|
+
message = JSON.parse(client.get( { 'Accept' => 'application/json' },
|
40
|
+
'/ReportingTools/GPServer/info/iteminfo',
|
40
41
|
{'f' => 'pjson'}).body)
|
41
42
|
|
42
43
|
client = RestBaby::Client.new('http://127.0.0.1:9001')
|
43
44
|
# post(BODY, HEADERS, PATH)
|
44
|
-
message = JSON.parse(client.post('{ "name": "Ben Franklin" }',
|
45
|
-
{ 'Content-Type' => 'application/json' },
|
45
|
+
message = JSON.parse(client.post('{ "name": "Ben Franklin" }',
|
46
|
+
{ 'Content-Type' => 'application/json' },
|
46
47
|
'/person').body)
|
47
|
-
# or
|
48
|
-
message = JSON.parse(client.post({ "name" => "Ben Franklin" }.to_json,
|
49
|
-
{ 'Content-Type' => 'application/json' },
|
48
|
+
# or
|
49
|
+
message = JSON.parse(client.post({ "name" => "Ben Franklin" }.to_json,
|
50
|
+
{ 'Content-Type' => 'application/json' },
|
50
51
|
'/person').body)
|
51
52
|
```
|
52
53
|
|
data/Rakefile
CHANGED
@@ -3,27 +3,56 @@ require 'rubygems'
|
|
3
3
|
require 'cucumber'
|
4
4
|
require 'cucumber/rake/task'
|
5
5
|
require 'coveralls/rake/task'
|
6
|
+
require 'rubocop/rake_task'
|
6
7
|
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
t.
|
8
|
+
version = RUBY_VERSION[0..2].split('.')[0..1].join('.').to_f
|
9
|
+
|
10
|
+
desc 'Run lint check RuboCop'
|
11
|
+
task :rubocop do
|
12
|
+
RuboCop::RakeTask.new do |t|
|
13
|
+
t.formatters = %w(files offenses)
|
14
|
+
t.options = [['--config', '.rubocop.yml']]
|
15
|
+
t.fail_on_error = true
|
14
16
|
end
|
15
17
|
end
|
16
18
|
|
19
|
+
desc 'Test'
|
17
20
|
Cucumber::Rake::Task.new(:features) do |t|
|
18
21
|
t.profile = 'default'
|
19
22
|
end
|
20
23
|
|
24
|
+
desc 'Check test coverage'
|
21
25
|
Coveralls::RakeTask.new
|
22
26
|
|
23
|
-
task default: [:features, 'coveralls:push']
|
24
|
-
|
25
27
|
task :clean do
|
26
28
|
`rm -rf doc`
|
27
29
|
`rm -rf .yardoc`
|
28
30
|
`git checkout doc`
|
29
31
|
end
|
32
|
+
|
33
|
+
if ENV['JRUBY'] || RUBY_PLATFORM == 'java' || version < 2.1
|
34
|
+
task default: [:features, 'coveralls:push', :rubocop]
|
35
|
+
|
36
|
+
elsif version > 2.0
|
37
|
+
desc 'Run lint check Reek'
|
38
|
+
require 'reek/rake/task'
|
39
|
+
Reek::Rake::Task.new(:lint) do |t|
|
40
|
+
t.name = 'reek'
|
41
|
+
t.config_file = 'config/config.reek'
|
42
|
+
t.source_files = 'lib/**/*.rb'
|
43
|
+
t.reek_opts = '-U'
|
44
|
+
t.fail_on_error = true
|
45
|
+
t.verbose = true
|
46
|
+
end
|
47
|
+
|
48
|
+
task default: [:features, 'coveralls:push', :rubocop, :reek]
|
49
|
+
else
|
50
|
+
desc 'Documentation'
|
51
|
+
require 'yard'
|
52
|
+
YARD::Rake::YardocTask.new do |t|
|
53
|
+
t.files = ['lib/**/*.rb', 'features/**/*.feature', 'features/**/*.rb']
|
54
|
+
end
|
55
|
+
|
56
|
+
# regular ruby default rake task
|
57
|
+
task default: [:features, 'coveralls:push', :rubocop, :reek]
|
58
|
+
end
|
data/config/config.reek
ADDED
@@ -0,0 +1,30 @@
|
|
1
|
+
exclude_paths:
|
2
|
+
- coverage
|
3
|
+
- doc
|
4
|
+
- features
|
5
|
+
- pkg
|
6
|
+
UtilityFunction:
|
7
|
+
exclude:
|
8
|
+
- RestBaby::Client#header_text
|
9
|
+
- RestBaby::Client#pretty_xml
|
10
|
+
ControlParameter:
|
11
|
+
exclude:
|
12
|
+
- RestBaby::Client#body_text
|
13
|
+
DuplicateMethodCall:
|
14
|
+
exclude:
|
15
|
+
- RestBaby::Client#print_request
|
16
|
+
DataClump:
|
17
|
+
exclude:
|
18
|
+
- RestBaby::Client
|
19
|
+
FeatureEnvy:
|
20
|
+
exclude:
|
21
|
+
- RestBaby::Client#print_request
|
22
|
+
InstanceVariableAssumption:
|
23
|
+
exclude:
|
24
|
+
- RestBaby::Client
|
25
|
+
TooManyInstanceVariables:
|
26
|
+
exclude:
|
27
|
+
- RestBaby::Client
|
28
|
+
TooManyStatements:
|
29
|
+
exclude:
|
30
|
+
- RestBaby::Client#send_request
|
data/cucumber.yml
CHANGED
@@ -1,4 +1,5 @@
|
|
1
1
|
default: FIG_NEWTON_FILE=mock.yml DEBUG_HTTP=true --tags ~@wip --no-source --color --format pretty
|
2
2
|
debug: FIG_NEWTON_FILE=mock.yml DEBUG_HTTP=true --no-source --color --format pretty
|
3
|
+
demo: FIG_NEWTON_FILE=mock.yml DEBUG_HTTP=false --tags ~@wip --no-source --color --format pretty
|
3
4
|
report: FIG_NEWTON_FILE=mock.yml DEBUG_HTTP=false --no-source --color --format progress --format html --out='features_<%= Time.new.strftime('%Y-%m-%d_%H_%M_%S') %>.html'
|
4
5
|
wip: FIG_NEWTON_FILE=mock.yml DEBUG_HTTP=true --tags @wip --color --format pretty
|
@@ -0,0 +1,20 @@
|
|
1
|
+
@nil
|
2
|
+
Feature: Create a basic rest client that can get, put, post, and delete
|
3
|
+
|
4
|
+
@core @put @nil
|
5
|
+
@nil.S1
|
6
|
+
Scenario: client rest PUT
|
7
|
+
Given I have a web service
|
8
|
+
And I have "PUT" service for "/nil" that requires no body
|
9
|
+
And I am a rest client
|
10
|
+
When I "PUT" to the web service with no body
|
11
|
+
Then I receive the no message
|
12
|
+
|
13
|
+
@core @post @nil
|
14
|
+
@nil.S2
|
15
|
+
Scenario: client rest POST
|
16
|
+
Given I have a web service
|
17
|
+
And I have "POST" service for "/nil" that requires no body
|
18
|
+
And I am a rest client
|
19
|
+
When I "POST" to the web service with no body
|
20
|
+
Then I receive the no message
|
@@ -24,6 +24,13 @@ Given(/^I have "(GET|PUT|POST|DELETE)" service for "([^"]*)"$/) do |type, path|
|
|
24
24
|
end
|
25
25
|
end
|
26
26
|
|
27
|
+
Given(/^I have "(PUT|POST)" service for "([^"]*)" that requires no body$/) do |type, path|
|
28
|
+
@path = path
|
29
|
+
@path = path
|
30
|
+
@mockservice.store_msg(type, path, nil,
|
31
|
+
{}, nil, nil, nil)
|
32
|
+
end
|
33
|
+
|
27
34
|
Given(/^I have an xml service for "([^"]*)"$/) do |path|
|
28
35
|
@path = path
|
29
36
|
@mockservice.store_msg('POST', path, DEFAULT_XML,
|
@@ -83,6 +90,15 @@ do |type, message|
|
|
83
90
|
end
|
84
91
|
end
|
85
92
|
|
93
|
+
When(/^I "(PUT|POST)" to the web service with no body$/) do |type|
|
94
|
+
case type.downcase
|
95
|
+
when 'put'
|
96
|
+
@response = @restbaby.put()
|
97
|
+
when 'post'
|
98
|
+
@response = @restbaby.post()
|
99
|
+
end
|
100
|
+
end
|
101
|
+
|
86
102
|
When(/^I "GET" from the web service with the parameters$/) do |table|
|
87
103
|
@response = @restbaby.get({}, nil, table.rows_hash)
|
88
104
|
end
|
@@ -105,3 +121,9 @@ Then(/^I receive the xml message$/) do
|
|
105
121
|
expect(@response.code).to eq('200')
|
106
122
|
expect(@response.body).to eq(DEFAULT_XML)
|
107
123
|
end
|
124
|
+
|
125
|
+
Then(/^I receive the no message$/) do
|
126
|
+
expect(@response.code).to eq('200')
|
127
|
+
expect(@response.body).to be_nil
|
128
|
+
end
|
129
|
+
|
data/lib/rest_baby.rb
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
# rest_baby.rb
|
2
|
-
# @author Dave McNulla
|
2
|
+
# @author Dave McNulla
|
3
3
|
# Originated: 2011
|
4
4
|
# This library was written to simplify communications with rest services.
|
5
5
|
|
@@ -15,8 +15,8 @@ require 'rest_baby/version'
|
|
15
15
|
module RestBaby
|
16
16
|
# Sends and receives data to a restful web service
|
17
17
|
class Client
|
18
|
-
PARAM_STARTER = '?'
|
19
|
-
PARAM_SEPARATOR = '&'
|
18
|
+
PARAM_STARTER = '?'.freeze
|
19
|
+
PARAM_SEPARATOR = '&'.freeze
|
20
20
|
|
21
21
|
# The WebService Response from the last call
|
22
22
|
attr_reader :wsresponse
|
@@ -84,7 +84,7 @@ module RestBaby
|
|
84
84
|
def post(body = nil, headers = {}, path = '')
|
85
85
|
uri = URI.parse("#{@url}#{path}")
|
86
86
|
request = Net::HTTP::Post.new(uri.request_uri)
|
87
|
-
request.body = body
|
87
|
+
request.body = body
|
88
88
|
send_request(uri, request, headers)
|
89
89
|
end
|
90
90
|
|
@@ -112,7 +112,7 @@ module RestBaby
|
|
112
112
|
def put(body = nil, headers = {}, path = '')
|
113
113
|
uri = URI.parse("#{@url}#{path}")
|
114
114
|
request = Net::HTTP::Put.new(uri.request_uri)
|
115
|
-
request.body = body
|
115
|
+
request.body = body
|
116
116
|
send_request(uri, request, headers)
|
117
117
|
end
|
118
118
|
|
@@ -120,7 +120,7 @@ module RestBaby
|
|
120
120
|
|
121
121
|
def send_request(uri, request, headers)
|
122
122
|
@headers.merge(headers).each { |key, value| request[key] = value }
|
123
|
-
request.basic_auth(@user, @password)
|
123
|
+
request.basic_auth(@user, @password)
|
124
124
|
http = Net::HTTP.new(uri.host, uri.port)
|
125
125
|
http.use_ssl = true if uri.scheme == 'https'
|
126
126
|
print_request(request, uri)
|
@@ -131,7 +131,7 @@ module RestBaby
|
|
131
131
|
|
132
132
|
def print_request(request, uri)
|
133
133
|
return nil unless @verbose
|
134
|
-
query =
|
134
|
+
query = uri.query == '' ? '' : "?#{uri.query}"
|
135
135
|
puts ">> REQUEST\n"\
|
136
136
|
"> URL: #{uri.scheme}://#{uri.host}:#{uri.port}#{uri.path}#{query}\n"\
|
137
137
|
"> Headers:\n"\
|
@@ -157,7 +157,7 @@ module RestBaby
|
|
157
157
|
end
|
158
158
|
|
159
159
|
def body_text(type, response_body)
|
160
|
-
|
160
|
+
response_body ||= '[Empty]'
|
161
161
|
case type
|
162
162
|
when 'application/json'
|
163
163
|
pretty_json(response_body)
|
data/lib/rest_baby/version.rb
CHANGED
data/rest_baby.gemspec
CHANGED
@@ -4,6 +4,9 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
|
4
4
|
require 'rest_baby/version'
|
5
5
|
|
6
6
|
Gem::Specification.new do |spec|
|
7
|
+
spec.required_ruby_version = '>= 2.0.0'
|
8
|
+
spec.required_rubygems_version = '>= 1.6.0'
|
9
|
+
|
7
10
|
spec.name = 'rest_baby'
|
8
11
|
spec.version = RestBaby::VERSION
|
9
12
|
spec.authors = ['Dave McNulla']
|
@@ -14,21 +17,18 @@ Gem::Specification.new do |spec|
|
|
14
17
|
spec.license = 'MIT'
|
15
18
|
|
16
19
|
spec.files = `git ls-files`.split($INPUT_RECORD_SEPARATOR)
|
17
|
-
spec.
|
18
|
-
spec.test_files = spec.files.grep(/^(test|spec|features)/)
|
20
|
+
spec.test_files = spec.files.grep(/^(features)/)
|
19
21
|
spec.require_paths = ['lib']
|
20
22
|
|
21
23
|
spec.add_dependency 'nokogiri', '~> 1.6'
|
22
24
|
spec.add_dependency 'json', '~> 1.8', '>= 1.8.0'
|
25
|
+
|
23
26
|
spec.add_development_dependency 'bundler', '~> 1.3'
|
24
27
|
spec.add_development_dependency 'rake', '~> 0'
|
25
28
|
spec.add_development_dependency 'cucumber', '~> 2.1', '>= 2.1.0'
|
26
29
|
spec.add_development_dependency 'fig_newton', '~> 0.9'
|
27
30
|
spec.add_development_dependency 'rspec', '~> 2.14', '>= 2.14.1'
|
28
31
|
spec.add_development_dependency 'webmock', '~> 1.13', '>= 1.13.0'
|
29
|
-
spec.add_development_dependency 'yard', '~> 0.8', '>= 0.8.7.6'
|
30
|
-
spec.add_development_dependency 'yard-cucumber', '~> 2.3', '>= 2.3.2'
|
31
|
-
spec.add_development_dependency 'redcarpet', '~> 3.3', '>= 3.3.0'
|
32
32
|
spec.add_development_dependency 'coveralls', '~> 0.7'
|
33
33
|
spec.add_development_dependency 'simplecov', '~> 0.11'
|
34
34
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rest_baby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.6.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dave McNulla
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-10-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: nokogiri
|
@@ -146,66 +146,6 @@ dependencies:
|
|
146
146
|
- - ">="
|
147
147
|
- !ruby/object:Gem::Version
|
148
148
|
version: 1.13.0
|
149
|
-
- !ruby/object:Gem::Dependency
|
150
|
-
name: yard
|
151
|
-
requirement: !ruby/object:Gem::Requirement
|
152
|
-
requirements:
|
153
|
-
- - "~>"
|
154
|
-
- !ruby/object:Gem::Version
|
155
|
-
version: '0.8'
|
156
|
-
- - ">="
|
157
|
-
- !ruby/object:Gem::Version
|
158
|
-
version: 0.8.7.6
|
159
|
-
type: :development
|
160
|
-
prerelease: false
|
161
|
-
version_requirements: !ruby/object:Gem::Requirement
|
162
|
-
requirements:
|
163
|
-
- - "~>"
|
164
|
-
- !ruby/object:Gem::Version
|
165
|
-
version: '0.8'
|
166
|
-
- - ">="
|
167
|
-
- !ruby/object:Gem::Version
|
168
|
-
version: 0.8.7.6
|
169
|
-
- !ruby/object:Gem::Dependency
|
170
|
-
name: yard-cucumber
|
171
|
-
requirement: !ruby/object:Gem::Requirement
|
172
|
-
requirements:
|
173
|
-
- - "~>"
|
174
|
-
- !ruby/object:Gem::Version
|
175
|
-
version: '2.3'
|
176
|
-
- - ">="
|
177
|
-
- !ruby/object:Gem::Version
|
178
|
-
version: 2.3.2
|
179
|
-
type: :development
|
180
|
-
prerelease: false
|
181
|
-
version_requirements: !ruby/object:Gem::Requirement
|
182
|
-
requirements:
|
183
|
-
- - "~>"
|
184
|
-
- !ruby/object:Gem::Version
|
185
|
-
version: '2.3'
|
186
|
-
- - ">="
|
187
|
-
- !ruby/object:Gem::Version
|
188
|
-
version: 2.3.2
|
189
|
-
- !ruby/object:Gem::Dependency
|
190
|
-
name: redcarpet
|
191
|
-
requirement: !ruby/object:Gem::Requirement
|
192
|
-
requirements:
|
193
|
-
- - "~>"
|
194
|
-
- !ruby/object:Gem::Version
|
195
|
-
version: '3.3'
|
196
|
-
- - ">="
|
197
|
-
- !ruby/object:Gem::Version
|
198
|
-
version: 3.3.0
|
199
|
-
type: :development
|
200
|
-
prerelease: false
|
201
|
-
version_requirements: !ruby/object:Gem::Requirement
|
202
|
-
requirements:
|
203
|
-
- - "~>"
|
204
|
-
- !ruby/object:Gem::Version
|
205
|
-
version: '3.3'
|
206
|
-
- - ">="
|
207
|
-
- !ruby/object:Gem::Version
|
208
|
-
version: 3.3.0
|
209
149
|
- !ruby/object:Gem::Dependency
|
210
150
|
name: coveralls
|
211
151
|
requirement: !ruby/object:Gem::Requirement
|
@@ -243,6 +183,7 @@ extra_rdoc_files: []
|
|
243
183
|
files:
|
244
184
|
- ".codeclimate.yml"
|
245
185
|
- ".coveralls.yml"
|
186
|
+
- ".gitignore"
|
246
187
|
- ".rubocop.yml"
|
247
188
|
- ".travis.yml"
|
248
189
|
- ChangeLog
|
@@ -250,6 +191,7 @@ files:
|
|
250
191
|
- LICENSE.txt
|
251
192
|
- README.md
|
252
193
|
- Rakefile
|
194
|
+
- config/config.reek
|
253
195
|
- config/environments/mock.yml
|
254
196
|
- cucumber.yml
|
255
197
|
- doc/MockRestService.html
|
@@ -309,6 +251,7 @@ files:
|
|
309
251
|
- doc/tag_list.html
|
310
252
|
- doc/top-level-namespace.html
|
311
253
|
- features/header_options.feature
|
254
|
+
- features/nil_body.feature
|
312
255
|
- features/print_response.feature
|
313
256
|
- features/rest_client.feature
|
314
257
|
- features/step_definitions/header_steps.rb
|
@@ -333,20 +276,21 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
333
276
|
requirements:
|
334
277
|
- - ">="
|
335
278
|
- !ruby/object:Gem::Version
|
336
|
-
version:
|
279
|
+
version: 2.0.0
|
337
280
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
338
281
|
requirements:
|
339
282
|
- - ">="
|
340
283
|
- !ruby/object:Gem::Version
|
341
|
-
version:
|
284
|
+
version: 1.6.0
|
342
285
|
requirements: []
|
343
286
|
rubyforge_project:
|
344
|
-
rubygems_version: 2.
|
287
|
+
rubygems_version: 2.5.1
|
345
288
|
signing_key:
|
346
289
|
specification_version: 4
|
347
290
|
summary: Small rest client developed to testing rest services.
|
348
291
|
test_files:
|
349
292
|
- features/header_options.feature
|
293
|
+
- features/nil_body.feature
|
350
294
|
- features/print_response.feature
|
351
295
|
- features/rest_client.feature
|
352
296
|
- features/step_definitions/header_steps.rb
|
@@ -356,4 +300,3 @@ test_files:
|
|
356
300
|
- features/support/utility.rb
|
357
301
|
- features/url_parameter.feature
|
358
302
|
- features/xml_message.feature
|
359
|
-
has_rdoc:
|