rspec-description_consistency 1.0.3 → 1.0.4

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
  SHA256:
3
- metadata.gz: 6d1d13615481394e4fd66245932bd731f9c698ece8d9a31fc74295ed9c602d87
4
- data.tar.gz: d4ff2f6dda1b6883e7c0f5053d8d1cd4c1da859c328d9df8a261d25c0355f121
3
+ metadata.gz: 1d6e5598bd81e991f1032f7b4bc283b432c52bc392847c239854095270fea483
4
+ data.tar.gz: 60cfd9fd4227dd970c0168ab91d2489121be5d584cf28d7fa3a62cc898fcd131
5
5
  SHA512:
6
- metadata.gz: ba7b906c6213f3ad9eb2b924a71746cf8c6e8b1fb50c004d0b609a6ed125a23cec6704ea0516a77104c10ba92ca513e593538e74280b26608f8044515c740acf
7
- data.tar.gz: ce059363eaacd1600b35bc8fd92e6f7ae539f0cc2200a9efe51ec802c986b80829f58c888ce56f3700b8d5d7e28c017583ad28d0b8e28bc18b68982841648d66
6
+ metadata.gz: 7c1f6c6070acde9552d1e3a4581565c60deb73a9d2ff7c9507b6cbcaa31a56def4bb80150231df8185c2b83ad36706be0d64b183529928cbde50f350e66135da
7
+ data.tar.gz: 65b82550950266021c6b1e08771a0383aa242e78045865075908770e9b170873b7cf21928e99f615c2b5b3ef29b10a888677cfc9998762b68b2174e4067bed5c
data/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  ## [Unreleased]
2
2
 
3
+ ## [1.0.4] - 2024-08-13
4
+
5
+ - Fix `ActiveModel` attribute misdetection [(#4)](https://github.com/viralpraxis/rspec-description_consistency/pull/4)
6
+
3
7
  ## [1.0.3] - 2024-07-04
4
8
 
5
9
  - Fix invalid private method verification [(#3)](https://github.com/viralpraxis/rspec-description_consistency/pull/3)
@@ -45,10 +45,9 @@ module RSpec
45
45
 
46
46
  if description.start_with?('#')
47
47
  return true if klass.instance_methods.include?(method_name)
48
- return false unless include_private
49
- return true if klass.private_instance_methods.include?(method_name)
48
+ return true if klass.respond_to?(:attribute_names) && klass.attribute_names.include?(method_name.to_s)
50
49
 
51
- klass.respond_to?(:attribute_names) && klass.attribute_names.include?(method_name.to_s)
50
+ include_private && klass.private_instance_methods.include?(method_name)
52
51
  elsif description.start_with?('.')
53
52
  correct_class_method?(method_name, klass, include_private: include_private)
54
53
  end
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Rspec
4
4
  module DescriptionConsistency
5
- VERSION = '1.0.3'
5
+ VERSION = '1.0.4'
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rspec-description_consistency
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.3
4
+ version: 1.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Iaroslav Kurbatov
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-07-04 00:00:00.000000000 Z
11
+ date: 2024-08-13 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: 'Automatic checking of consistency of descriptions in context and describe
14
14
  blocks, and class or module methods.
@@ -57,7 +57,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
57
57
  - !ruby/object:Gem::Version
58
58
  version: '0'
59
59
  requirements: []
60
- rubygems_version: 3.5.3
60
+ rubygems_version: 3.5.15
61
61
  signing_key:
62
62
  specification_version: 4
63
63
  summary: RSpec extension for automatic description consistency verification