rspec-sleeping_king_studios 2.0.0.beta.1 → 2.0.0.beta.2

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: 4f6b435b34abdf1b87b2496605d4472339e97b51
4
- data.tar.gz: 9ab33137c4cdb76bdd1957e060814a5a8a6a23cd
3
+ metadata.gz: 9ac96e7fae3fdf94aa39e7ebfecccfc39766ada0
4
+ data.tar.gz: 0d96c3c2402360bbf600fce1bd882ea38d8f341f
5
5
  SHA512:
6
- metadata.gz: 3fadfe034ff61756ef19b23eb4d4f15e7239b0e26a770cfa9711445d216e27efb487206b20848cae983732def47b3c45c2225778ddd9dc00023d2a742a5996ff
7
- data.tar.gz: 6ea0170359b50b8b5a012085430ea5fa3cb92ee9fe563b38dcdc53ffdcee2ae7f0a9802c31d6f394a6d5b91759e4f5c15c90c225996eee865dd3ba6034348067
6
+ metadata.gz: e5ed09efe3e51e5900e6332fe5e51677c17e47d874aa85304ddad33ab93c12b3f8c5006371e8e80df4efaeeeecdae1fb06fe02bf1a10663df24d7cb7a3b204ed
7
+ data.tar.gz: 5d4abb850b85fbfffb3544268c4b47b07038816f03e2be7ded0a43ce1bf9963b566ca66db81fa6958eeb491667ac3621ccc8815dbb7807347a8ce2c60793405e
@@ -8,7 +8,7 @@ module RSpec::SleepingKingStudios::Matchers::Shared
8
8
  # Checks whether the value of the reader matches the expected value. If the
9
9
  # value looks like an RSpec matcher (it responds to :matches?), runs
10
10
  # value.matches?(); otherwise checks for equality using :==.
11
- #
11
+ #
12
12
  # @return [Boolean] true if the value matches the expected value; otherwise
13
13
  # false.
14
14
  def matches_reader_value?
@@ -17,13 +17,13 @@ module RSpec::SleepingKingStudios::Matchers::Shared
17
17
 
18
18
  actual_value = @actual.send(@expected)
19
19
 
20
- @matches_reader_value = @value.respond_to?(:matches?) ?
20
+ @matches_reader_value = (@value.respond_to?(:matches?) && @value.respond_to?(:description)) ?
21
21
  @value.matches?(actual_value) :
22
22
  @value == actual_value
23
23
  end # method matches_reader_value?
24
24
 
25
25
  # Checks whether the object responds to the reader method :#{property}.
26
- #
26
+ #
27
27
  # @return [Boolean] true if the object responds to the method; otherwise
28
28
  # false.
29
29
  def responds_to_reader?
@@ -31,7 +31,7 @@ module RSpec::SleepingKingStudios::Matchers::Shared
31
31
  end # method responds_to_reader?
32
32
 
33
33
  # Checks whether the object responds to the writer method :#{property}=.
34
- #
34
+ #
35
35
  # @return [Boolean] true if the object responds to the method; otherwise
36
36
  # false.
37
37
  def responds_to_writer?
@@ -39,12 +39,12 @@ module RSpec::SleepingKingStudios::Matchers::Shared
39
39
  end # method responds_to_reader?
40
40
 
41
41
  # Formats the expected value as a human-readable string. If the value looks
42
- # like an RSpec matcher (it responds to :matches?), calls
42
+ # like an RSpec matcher (it responds to :matches? and :description), calls
43
43
  # value#description; otherwise calls value#inspect.
44
- #
44
+ #
45
45
  # @return [String] the value as a human-readable string.
46
46
  def value_to_string
47
- return @value.description if @value.respond_to?(:matches?)
47
+ return @value.description if @value.respond_to?(:matches?) && @value.respond_to?(:description)
48
48
 
49
49
  @value.inspect
50
50
  end # method value_to_string
@@ -8,7 +8,7 @@ module RSpec
8
8
  MINOR = 0
9
9
  PATCH = 0
10
10
  PRERELEASE = 'beta'
11
- BUILD = 1
11
+ BUILD = 2
12
12
 
13
13
  def self.to_gem_version
14
14
  str = "#{MAJOR}.#{MINOR}.#{PATCH}"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rspec-sleeping_king_studios
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.0.beta.1
4
+ version: 2.0.0.beta.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rob "Merlin" Smith