rspec_api_helpers 0.1.5 → 0.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
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 835fbac209890b97af6235d88e7a78e6c19fcea2
|
4
|
+
data.tar.gz: dc06e13a50f31e4ad36198a05cd11084f3931747
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9ac6b7d598612def879b18c57eef843c7d820ee383b002ae0d2f9c2bea02c67a551ed5102e89fd834225dc65a148902fae711f37b77f112367decc03551c1fc9
|
7
|
+
data.tar.gz: 529e7886931393af13d4800e20a4838cc8b5fea5f8d9a2ba354b77f1de48095e18e5358e70cd335fd46337e7957f9dd067326a76dbd334327a03803fa0f86746
|
@@ -1,5 +1,6 @@
|
|
1
1
|
require 'factory_girl'
|
2
2
|
require 'json'
|
3
|
+
require 'active_support/core_ext'
|
3
4
|
|
4
5
|
module RspecApiHelpers
|
5
6
|
module Strategies
|
@@ -11,7 +12,7 @@ module RspecApiHelpers
|
|
11
12
|
delegate :association, to: :@strategy
|
12
13
|
|
13
14
|
def result(evaluation)
|
14
|
-
JSON.parse
|
15
|
+
JSON.parse(@strategy.result(evaluation).to_json).symbolize_keys
|
15
16
|
end
|
16
17
|
end
|
17
18
|
end
|
data/spec/hash_strategy_spec.rb
CHANGED
@@ -13,7 +13,7 @@ describe RspecApiHelpers::Strategies::HashStrategy do
|
|
13
13
|
subject { FactoryGirl.hash :person }
|
14
14
|
|
15
15
|
it 'represents user in JSON format' do
|
16
|
-
hash = {
|
16
|
+
hash = { :email => 'test@test.com', :name => 'Mrs. Mock' }
|
17
17
|
expect(subject).to eq hash
|
18
18
|
end
|
19
19
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rspec_api_helpers
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ian Ker-Seymer
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-08-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|