api_pi 0.2.2 → 0.2.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 593aca0cfdef51079c984f36b65e73ff91782b6a
4
- data.tar.gz: 36490547835fc125f4f35239921a11c36cacdcd4
3
+ metadata.gz: 9bb93d26d0c2c0268df45e1d0c7b65bfac8fa71c
4
+ data.tar.gz: 625d48a0cd5faa4c4c25d4ef2c0eb95954214edb
5
5
  SHA512:
6
- metadata.gz: 600be817d0712ec773b48ebee4b2fe4b6e04421e6f64f6043afc37e0fc618cc610b3177956a49b7a442639097ab73c8277f389360ae30d248c1f1964de05a3ea
7
- data.tar.gz: 1956d03a05709903c9dedcc3e67358783984989f1c82f5adf0de666a3bed69bdc66d4856cb8002ab9b2c4a95b7d1010cdcc560624d82308c4db19b4a76a49786
6
+ metadata.gz: d608c3bf845f9945b2904a12c22ac8c66b3213b794e090fd4b2b9d4c7728e0d36652a9d2c8594d25ef423f64bb952e0702a665ae9129bd059883133f150b2f30
7
+ data.tar.gz: 05181cb0c380d83d1fb509ec88ae90900abeb64edaff4c187e7ad250a1b5a06de4b7db4fb206d042a47ed66e6d95350d1aa6df6d5f0ac444bd723fedc7a87608
data/README.md CHANGED
@@ -8,13 +8,9 @@ An example test can be found in the example/ directory.
8
8
 
9
9
  Api P.I. requires ruby 2.0.0+
10
10
 
11
- Clone this repository to your machine:
11
+ Install the gem:
12
12
 
13
- $ git clone git@github.ubermind.com:bewoodall/api_pi.git && cd api_pi
14
-
15
- Build and Install the gem:
16
-
17
- $ gem build api_pi.gemspec && gem install api_pi-VERSION.gem
13
+ $ gem install api_pi
18
14
 
19
15
  ## Usage
20
16
 
@@ -25,7 +21,7 @@ request to a URL.
25
21
 
26
22
  get "http://url-to-test.com/object.json" do...end
27
23
 
28
- The `get` method takes a URL string and then is fed a block to build tests.
24
+ The `get` method takes a URL string and is then fed a block to build tests.
29
25
 
30
26
  Once you GET your URL, you are ready to create test blocks.
31
27
 
@@ -187,6 +183,25 @@ is present in a JSON block:
187
183
  "works".stripped? => true
188
184
  " spaces ".stripped? => false
189
185
 
186
+ ## Inspecting
187
+
188
+ To inspect your json:
189
+
190
+ # ruby inspect_myjson.rb
191
+
192
+ which would give you output similar to:
193
+
194
+ Requesting JSON from http://apipi.apiary.io/tests and testing
195
+ - headers
196
+ - body results.string
197
+ - results.int
198
+ - results
199
+ - results.array
200
+
201
+ 5 tests, 5 succeeded, 0 failed
202
+
203
+ Passing tests yield a response code of 0, and failed tests yield 1.
204
+
190
205
  ## Testing
191
206
 
192
207
  Api-PI is testing using Ruby's MiniTest framework. To run tests:
@@ -15,9 +15,10 @@ Gem::Specification.new do |g|
15
15
  g.files = `git ls-files`.split("\n")
16
16
  g.test_files = `git ls-files -- test/*`.split("\n")
17
17
 
18
- g.extra_rdoc_files = ["README.md"]
18
+ g.extra_rdoc_files = ["README.md"]
19
+ g.required_ruby_version = '>= 2.0.0'
19
20
 
20
- g.add_dependency 'map', '~> 6.5'
21
+ g.add_dependency 'map', '~> 6.5'
21
22
  g.add_development_dependency 'webmock', '~> 1.17'
22
23
  g.add_development_dependency 'rake', '~> 10.1'
23
24
  end
@@ -1,3 +1,3 @@
1
1
  module ApiPi
2
- VERSION = '0.2.2'
2
+ VERSION = '0.2.3'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: api_pi
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.2
4
+ version: 0.2.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ben Woodall
@@ -88,7 +88,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
88
88
  requirements:
89
89
  - - '>='
90
90
  - !ruby/object:Gem::Version
91
- version: '0'
91
+ version: 2.0.0
92
92
  required_rubygems_version: !ruby/object:Gem::Requirement
93
93
  requirements:
94
94
  - - '>='