restspec 0.2.1 → 0.2.2

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: d901b5b31ccd31cb10ed6aa3d3eb64dfc9817595
4
- data.tar.gz: 62319f6fd801767b52842413f5200bd40baaeac7
3
+ metadata.gz: b26843a83bede22b733ac6f705d2a222e5026ead
4
+ data.tar.gz: 4b842294033cf03caaf560f3acdcfd6d8a509e34
5
5
  SHA512:
6
- metadata.gz: df3d6838f88efe8fc53514d040aee2c93bb578a79265bc670b3ead0c82c124885a02b795c1be6c5e482bbb596b7fa8bc43d9b346d09dbecbd04bf343a3c68936
7
- data.tar.gz: f9325534e3990ac883d5024d8f331448ae69cc31ccc520bf53be978e45d7d77388cc719fb005206178f82e164dc8643371eef20eb10ba52d2e6aad48f0495cc1
6
+ metadata.gz: ab90ca0c0d75fbba573b983514ad3d31a38d0fcbedf8111e419eb7401b54f10c11eaac0a0b6d51e00ea6e984d54cfd7c7534224082a703e3c1a29e10c9c96947
7
+ data.tar.gz: 41a7db86cfdcfd83a86e9d53ec5be7a7a821320a84535b969706dacaf3151b10ee9e5ac5cd7d32c4fd1c30af86825b30a01001693f616eb9e282de61955755a0
@@ -45,11 +45,15 @@ module Restspec::Schema::Types
45
45
 
46
46
  def get_sample_item
47
47
  fetch_endpoint = get_index_endpoint
48
- fetch_endpoint.execute.body.try(:sample)
48
+ if fetch_endpoint.present?
49
+ fetch_endpoint.execute.body.try(:sample)
50
+ end
49
51
  end
50
52
 
51
53
  def create_response
52
- create_endpoint.execute(body: create_example)
54
+ if create_endpoint.present?
55
+ create_endpoint.execute(body: create_example)
56
+ end
53
57
  end
54
58
 
55
59
  def get_create_endpoint
@@ -1,3 +1,3 @@
1
1
  module Restspec
2
- VERSION = "0.2.1"
2
+ VERSION = "0.2.2"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: restspec
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - juliogarciag
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-01-01 00:00:00.000000000 Z
11
+ date: 2015-01-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake