rspec-controller-matchers 0.0.4 → 0.0.5

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: b68e7150ead2a591290bfee5743b7112e5ccb891
4
- data.tar.gz: b89f1e1e92f3f3e0ae9b071a7ad08a71bafd59f7
3
+ metadata.gz: b48cd41d8eaebf1782ddd34b782836723e10ebdc
4
+ data.tar.gz: 6307fa9f0f8376ab887dec86780a78422887f49f
5
5
  SHA512:
6
- metadata.gz: 359195d304442c3f00d95efaaad3d9b2cdf8b10b299bcb40171b7ba80fc199fb37f4c782bb0fd34bcb85a9210470bd034678c00c320d5b6cedd7bd6e029b12bf
7
- data.tar.gz: 917def3e327ac15b12f5388b906c9c163e264bd00b157524b48c0cada22545f2c7beaffa94da276816a4f96992b86c455858e7815d9450d4300bb0c872dba1cb
6
+ metadata.gz: c9c9e35cb16ea71dece0a0e3109082378f1724e3cf9e47868a288217c21ab42cb53721c6723c5682fdcf97e5fa3604cab1f15e20fad225af4707bec0f9fbf1bc
7
+ data.tar.gz: 1641d787523bf6cfc8ea21875fab5299b8f5200bbd251584c7ddf330f9d93ba91ebae34715d179e2b7bfca9974770a9540e3c33b9c339130d9fda3bd55b4c0a8
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.0.4
1
+ 0.0.5
@@ -3,3 +3,4 @@ require "rspec/matchers/render_local_matcher"
3
3
  require "rspec/matchers/destroy_record_matcher"
4
4
  require "rspec/matchers/create_record_matcher"
5
5
  require "rspec/matchers/update_record_matcher"
6
+ require "rspec/matchers/be_record_matcher"
@@ -0,0 +1,6 @@
1
+ RSpec::Matchers.define :be_record do |record|
2
+ match do |actual|
3
+ expect(actual).to be_kind_of(record.class)
4
+ expect(actual).to have_attributes(record.class.primary_key => record[record.class.primary_key])
5
+ end
6
+ end
@@ -2,11 +2,11 @@
2
2
  # DO NOT EDIT THIS FILE DIRECTLY
3
3
  # Instead, edit Juwelier::Tasks in Rakefile, and run 'rake gemspec'
4
4
  # -*- encoding: utf-8 -*-
5
- # stub: rspec-controller-matchers 0.0.4 ruby lib
5
+ # stub: rspec-controller-matchers 0.0.5 ruby lib
6
6
 
7
7
  Gem::Specification.new do |s|
8
8
  s.name = "rspec-controller-matchers".freeze
9
- s.version = "0.0.4"
9
+ s.version = "0.0.5"
10
10
 
11
11
  s.required_rubygems_version = Gem::Requirement.new(">= 0".freeze) if s.respond_to? :required_rubygems_version=
12
12
  s.require_paths = ["lib".freeze]
@@ -28,6 +28,7 @@ Gem::Specification.new do |s|
28
28
  "Rakefile",
29
29
  "VERSION",
30
30
  "lib/rspec-controller-matchers.rb",
31
+ "lib/rspec/matchers/be_record_matcher.rb",
31
32
  "lib/rspec/matchers/create_record_matcher.rb",
32
33
  "lib/rspec/matchers/destroy_record_matcher.rb",
33
34
  "lib/rspec/matchers/render_local_matcher.rb",
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rspec-controller-matchers
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.4
4
+ version: 0.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stevo
@@ -97,6 +97,7 @@ files:
97
97
  - Rakefile
98
98
  - VERSION
99
99
  - lib/rspec-controller-matchers.rb
100
+ - lib/rspec/matchers/be_record_matcher.rb
100
101
  - lib/rspec/matchers/create_record_matcher.rb
101
102
  - lib/rspec/matchers/destroy_record_matcher.rb
102
103
  - lib/rspec/matchers/render_local_matcher.rb