limit_detectors 1.0.8 → 1.0.9

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: c00897fc2c81f4e005433521f0328e4ccadfb1bfcf2a1104de622a3cbdeaf05a
4
- data.tar.gz: 67eab1adedfe668ff38560da47301418138532f2661adff0b21bf5522df4664e
3
+ metadata.gz: 31b55f9851b0df639be993b00321760b5ca6ed5de3f700c30e513a866ec82d3d
4
+ data.tar.gz: 145748f0103fda2ee9d363bc2e9074348f99b2ad4195519c13c651c4d837335c
5
5
  SHA512:
6
- metadata.gz: 338c15b03a70adedc1dc8b1f0f59c4b525f517a47549c0f37d711b869869c6b9b6a21e9f2a066a4c5d47802e7d48f7496e098ceb6c6e59859b1e4565eb2424f8
7
- data.tar.gz: 6b825beedcc67b40b142433af7bfbd2fd1060781c6a751c9a8987c1a34fa6d7b4dd850079d820f6d91500e38de042d0d6b5f6d01af0276246daf12c49ee1841f
6
+ metadata.gz: 53a1c72995dd9d98f81a19cf386514d6bb6bed6434ab3c42d1d5ca77c696631707fce9f691d19ba2598f475738d3e3097ba2b5515fcec2c1e84699d4bdf7fbf8
7
+ data.tar.gz: e928030e0c253403f856a46161606d09d3f8ace605a15db25e8100ce8397b23ee7db17549c12a02cfa2fa2b36c311f545d5f95d170140c74a62139effb800b79
data/.codeclimate.yml ADDED
@@ -0,0 +1,3 @@
1
+ plugins:
2
+ rubocop:
3
+ enabled: true
@@ -19,7 +19,7 @@ jobs:
19
19
  runs-on: ubuntu-latest
20
20
  strategy:
21
21
  matrix:
22
- ruby-version: ['3.0', '3.1.3', '3.2.2', '3.3.0', 'jruby', 'truffleruby']
22
+ ruby-version: ['3.2.9', '3.3.9', '3.4.6', 'jruby', 'truffleruby']
23
23
 
24
24
  steps:
25
25
  - uses: actions/checkout@v3
@@ -27,6 +27,8 @@ jobs:
27
27
  uses: ruby/setup-ruby@v1
28
28
  with:
29
29
  ruby-version: ${{ matrix.ruby-version }}
30
- bundler-cache: true # runs 'bundle install' and caches installed gems automatically
30
+ bundler-cache: false # runs 'bundle install' and caches installed gems automatically
31
+ - name: Run bundler
32
+ run: bundle install
31
33
  - name: Run tests
32
34
  run: bundle exec rake
data/.rubocop.yml CHANGED
@@ -1,8 +1,40 @@
1
+ plugins:
2
+ - rubocop-rake
3
+ - rubocop-rspec
4
+
1
5
  AllCops:
2
- NewCops: enable
6
+ NewCops: disable
3
7
  Exclude:
4
8
  - 'bin/**/*'
9
+ TargetRubyVersion: 3.1
5
10
 
6
11
  Style/EmptyMethod:
7
12
  Enabled: false
8
13
 
14
+ Naming/VariableNumber:
15
+ EnforcedStyle: snake_case
16
+
17
+ Style/OpenStructUse:
18
+ Enabled: false
19
+
20
+ RSpec/MultipleExpectations:
21
+ Enabled: true
22
+ Max: 8
23
+
24
+ Lint/EmptyBlock:
25
+ Enabled: false
26
+
27
+ RSpec/NamedSubject:
28
+ Enabled: false
29
+
30
+ RSpec/MessageSpies:
31
+ Enabled: false
32
+
33
+ RSpec/DescribeClass:
34
+ Enabled: false
35
+
36
+ RSpec/MultipleDescribes:
37
+ Enabled: false
38
+
39
+ RSpec/DescribeMethod:
40
+ Enabled: false
data/Gemfile CHANGED
@@ -5,4 +5,20 @@ source 'https://rubygems.org'
5
5
  # Specify your gem's dependencies in limit_detectors.gemspec
6
6
  gemspec
7
7
 
8
+ gem 'ostruct'
9
+ gem 'reline', '~> 0.6.0'
10
+ gem 'rubocop-rake', '~> 0.7'
11
+ gem 'rubocop-rspec', '~> 3.7'
8
12
 
13
+ group :development, :test do
14
+ gem 'bundler'
15
+ gem 'guard-rspec'
16
+ gem 'pry', '~> 0.15.2'
17
+ gem 'pry-doc', '~> 1.5.0'
18
+ gem 'rake', '~> 13.2.1'
19
+ gem 'rb-fsevent'
20
+ gem 'rspec', '~> 3.13'
21
+ gem 'rubocop'
22
+ gem 'terminal-notifier'
23
+ gem 'terminal-notifier-guard'
24
+ end
data/LICENSE.txt CHANGED
@@ -1,4 +1,4 @@
1
- Copyright (c) 2014 Stephan Kämper
1
+ Copyright (c) 2014 Stephan Kämper
2
2
 
3
3
  MIT License
4
4
 
data/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # LimitDetectors
2
2
 
3
- Some methods to detect whether an Enumberable object contains a constrained number of elements that match a given condition
3
+ Some methods to detect whether an Enumerable object contains a constrained number of elements that match a given condition
4
4
 
5
5
  A second reason to create this gem is to explore various other services -- see the status list below.
6
6
 
@@ -8,7 +8,7 @@ A second reason to create this gem is to explore various other services -- see t
8
8
  ## Status & Links
9
9
 
10
10
  * Version: [![Gem Version](https://badge.fury.io/rb/limit_detectors.svg)](http://badge.fury.io/rb/limit_detectors)
11
- * GitHub Actions:
11
+ * GitHub Actions:
12
12
  * [![Main workflow: unit tests](https://github.com/s2k/limit_detectors/actions/workflows/ruby.yml/badge.svg)](https://github.com/s2k/limit_detectors/actions)
13
13
  * [![CodeQL](https://github.com/s2k/limit_detectors/actions/workflows/codeql-analysis.yml/badge.svg)](https://github.com/s2k/limit_detectors/actions/workflows/codeql-analysis.yml)
14
14
  * Code Climate: [![Maintainability](https://api.codeclimate.com/v1/badges/f29deb5bcd4e2ad44d25/maintainability)](https://codeclimate.com/github/s2k/limit_detectors/maintainability)
@@ -79,10 +79,9 @@ puts e.at_most?(42) { |c| 'b' == c }
79
79
 
80
80
  This gem is tested with these Ruby versions (MRI, unless JRuby):
81
81
 
82
- - 3.0.x
83
- - 3.1.x
84
- - 3.2.x
85
- - 3.3.x
82
+ - 3.2.9
83
+ - 3.3.9
84
+ - 3.4.6
86
85
 
87
86
  as well as a current version of JRuby and TruffleRuby
88
87
 
@@ -100,7 +99,7 @@ A more detailed description is at https://opensource.com/article/19/7/create-pul
100
99
 
101
100
  After `bundle install` (or `update`) you can now use [`Guard`](https://github.com/guard/guard).
102
101
 
103
- In the project directory run
102
+ In the project directory run
104
103
 
105
104
  ```
106
105
  bundle exec guard
data/Rakefile CHANGED
@@ -2,11 +2,17 @@
2
2
 
3
3
  require 'bundler/gem_tasks'
4
4
  require 'rspec/core/rake_task'
5
+ require 'rake/testtask'
6
+ require 'rubocop/rake_task'
7
+ require 'rubocop'
5
8
 
6
9
  RSpec::Core::RakeTask.new :spec
7
10
 
8
- task default: :spec
9
-
11
+ desc 'Open a pry console with the gem loaded'
10
12
  task :console do
11
- exec 'irb -I ./lib -r limit_detectors'
13
+ exec 'pry -I ./lib -r limit_detectors'
12
14
  end
15
+
16
+ RuboCop::RakeTask.new
17
+
18
+ task default: %i[spec rubocop]
data/example/example.rb CHANGED
@@ -2,10 +2,13 @@
2
2
 
3
3
  require 'limit_detectors'
4
4
 
5
+ # A simple Example class to demonstrate how the
6
+ # methods from limit_detectors can be used.
7
+ #
5
8
  class Example
6
9
  include Enumerable
7
- def each(&block)
8
- ('a'..'d').each(&block)
10
+ def each(&)
11
+ ('a'..'d').each(&)
9
12
  end
10
13
  end
11
14
 
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module LimitDetectors
4
- VERSION = '1.0.8'
4
+ VERSION = '1.0.9'
5
5
  end
@@ -2,29 +2,35 @@
2
2
 
3
3
  require 'limit_detectors/version'
4
4
 
5
+ # LimitDetectors provides methods (that depend on `Enumerable` being present)
6
+ # to detect if an `Enumerable` object complies to the specified limitation.
7
+ # For example, there's a method #at_most that returns `true`if the given
8
+ # enumerable object contains _at most_ the given number of elements that match
9
+ # the given constrains (provided as a proc/lambda).
10
+ #
5
11
  module LimitDetectors
6
12
  # Deprecated, use at_most? instead
7
- def at_most(limit, &block)
13
+ def at_most(limit, &)
8
14
  Kernel.warn "'at_most' is deprecated, use 'at_most?' instead"
9
- at_most? limit, &block
15
+ at_most? limit, &
10
16
  end
11
17
 
12
18
  # Deprecated, use at_least? instead
13
- def at_least(limit, &block)
19
+ def at_least(limit, &)
14
20
  Kernel.warn "'at_least' is deprecated, use 'at_least?' instead"
15
- at_least? limit, &block
21
+ at_least? limit, &
16
22
  end
17
23
 
18
24
  # Check whether the condition given in the block
19
25
  # occurs at most limit times in the collection
20
- def at_most?(limit, &block)
21
- occurrences_of(&block) <= limit
26
+ def at_most?(limit, &)
27
+ occurrences_of(&) <= limit
22
28
  end
23
29
 
24
30
  # Check whether the condition given in the block
25
31
  # occurs at least limit times in the collection
26
- def at_least?(limit, &block)
27
- occurrences_of(&block) >= limit
32
+ def at_least?(limit, &)
33
+ occurrences_of(&) >= limit
28
34
  end
29
35
 
30
36
  # Count how often the condition given in the block
@@ -5,29 +5,18 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
5
5
  require 'limit_detectors/version'
6
6
 
7
7
  Gem::Specification.new do |spec|
8
- spec.name = 'limit_detectors'
9
- spec.version = LimitDetectors::VERSION
10
- spec.authors = ['Stephan Kämper']
11
- spec.email = ['the.tester@seasidetesting.com']
12
- spec.summary = 'Detect certain conditions of elements of an Enumerable object'
13
- spec.description = 'Some methods to detect whether an Enumerable object contains a constrained number of elements that match a given condition.'
14
- spec.homepage = ''
15
- spec.license = 'MIT'
16
-
17
- spec.files = `git ls-files -z`.split("\x0")
18
- spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
19
- spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
20
- spec.require_paths = ['lib']
21
-
22
- spec.add_development_dependency 'bundler'
23
- spec.add_development_dependency 'guard-rspec'
24
- spec.add_development_dependency 'pry', '~> 0.14.2'
25
- spec.add_development_dependency 'pry-doc', '~> 1.4.0'
26
- spec.add_development_dependency 'rake', '~> 13.0.6'
27
- spec.add_development_dependency 'rb-fsevent'
28
- spec.add_development_dependency 'rspec', '~> 3.12'
29
- spec.add_development_dependency 'terminal-notifier'
30
- spec.add_development_dependency 'terminal-notifier-guard'
8
+ spec.name = 'limit_detectors'
9
+ spec.version = LimitDetectors::VERSION
10
+ spec.authors = ['Stephan Kämper']
11
+ spec.email = ['the.tester@seasidetesting.com']
12
+ spec.summary = 'Detect conditions of elements of an Enumerable object'
13
+ spec.description = 'Detect if an Enumerable object contains at least/most x elements matching a condition.'
14
+ spec.homepage = 'https://github.com/s2k/limit_detectors'
15
+ spec.license = 'MIT'
16
+ spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
17
+ spec.require_paths = ['lib']
18
+ spec.required_ruby_version = '>= 3.1.0'
19
+ spec.files = `git ls-files -z`.split("\x0")
31
20
 
32
21
  spec.metadata = {
33
22
  'rubygems_mfa_required' => 'true'
@@ -4,100 +4,111 @@ require 'set'
4
4
 
5
5
  Array.include LimitDetectors
6
6
 
7
- describe '#at_most' do
7
+ describe Array, '#at_most?' do
8
8
  it 'is true for an empty Array' do
9
- expect(Kernel).to_not receive(:warn)
10
- expect([].at_most?(5) { true }).to be_truthy
11
- expect([].at_most?(0) { true }).to be_truthy
12
- expect([].at_most?(1) { true }).to be_truthy
13
- expect([].at_most?(5) { :foo }).to be_truthy
9
+ expect(Kernel).not_to receive(:warn)
10
+ expect([]).to be_at_most(5) { true }
11
+ expect([]).to be_at_most(0) { true }
12
+ expect([]).to be_at_most(1) { true }
13
+ expect([]).to be_at_most(5) { :foo }
14
14
  end
15
15
 
16
16
  it 'is true if the criterion is met once' do
17
- expect(["it's there"].at_most?(1) { |el| el == "it's there" }).to be_truthy
17
+ expect(["it's there"]).to be_at_most(1) { |el| el == "it's there" }
18
18
  end
19
19
 
20
20
  it 'is true if all elements meet the criterion and the size is the given maximum number' do
21
- expect([1, 1, 1].at_most?(3) { |e| e == 1 })
21
+ expect([1, 1, 1]).to be_at_most(3) { |e| e == 1 }
22
22
  end
23
23
 
24
24
  it 'is false if not enough elements meet the criterion' do
25
- expect([1, 2, 4].at_most?(1, &:even?)).to be_falsey
25
+ expect([1, 2, 4].at_most(1, &:even?)).not_to be_truthy
26
26
  end
27
27
 
28
28
  it 'is true if 0 elements are expected to match' do
29
- r = Array.new(10) { rand }
30
- expect(r.at_most?(0) { |i| i > 2 }).to be_truthy
29
+ r = described_class.new(10) { rand }
30
+ expect(r).to be_at_most(0) { |i| i > 2 }
31
31
  end
32
+ end
32
33
 
33
- describe 'Hash#at_most' do
34
- Hash.include LimitDetectors
35
- it 'detects a condition based on key as well as value properties' do
36
- h = { 'foo' => 1, 'bar' => 4, 'baz' => 5, 'bum' => 1, 'fum' => 0 }
37
- expect(h.at_most?(3) { |ky, vl| ky.match(/^b/) || vl > 1 }).to be_truthy
38
- end
34
+ describe Hash, '#at_most?' do
35
+ described_class.include LimitDetectors
36
+ it 'detects a condition based on key as well as value properties' do
37
+ h = { 'foo' => 1, 'bar' => 4, 'baz' => 5, 'bum' => 1, 'fum' => 0 }
38
+ expect(h).to be_at_most(3) { |ky, vl| ky.match(/^b/) || vl > 1 }
39
39
  end
40
40
  end
41
41
 
42
- describe '#at_least' do
42
+ describe Array, '#at_least?' do
43
43
  it 'is false for an empty Array, if at least one is expected' do
44
- expect(Kernel).to_not receive(:warn)
45
- expect([].at_least?(1) { true }).to be_falsey
44
+ expect(Kernel).not_to receive(:warn)
45
+ [].at_least?(2) { |i| i > 2 }
46
+ end
47
+
48
+ it 'is false for empty Arrays when one elements is expected' do
49
+ expect([]).not_to be_at_least(1) { false }
50
+ end
51
+
52
+ it 'is true if the expected number is 0 and Hash is empty' do
53
+ expect({}).to be_at_least(0) { false }
46
54
  end
47
55
 
48
56
  it 'is true if the expected number is 0 and Array is empty' do
49
- expect([].at_least?(0) { true }).to be_truthy
50
- expect({}.at_least?(0) { false }).to be_truthy
57
+ expect([]).to be_at_least(0) { true }
51
58
  end
52
59
 
53
60
  it 'is false if the container ist smaller than the expected number' do
54
61
  size = 10
55
- expect(Array.new(10).at_least?(size + 1) { true }).to be_falsey
62
+ expect(described_class.new(size)).not_to be_at_least(size + 1) { true }
56
63
  end
57
64
 
58
65
  it 'is true if the criterion is met and expected once' do
59
- expect(["it's there"].at_least?(1) { |el| el == "it's there" }).to be_truthy
66
+ expect(["it's there"]).to be_at_least(1) { |el| el == "it's there" }
60
67
  end
61
68
 
62
69
  it 'is false for an empty Array if you expect at least 1' do
63
- expect([].at_least?(1) { true }).to be_falsey
70
+ expect([]).not_to be_at_least(1) { true }
64
71
  end
65
72
 
66
73
  it 'is true for an empty Array if you expect at least 0' do
67
- expect([].at_least?(0) {}).to be_truthy
74
+ expect([]).to be_at_least(0) {}
68
75
  end
69
76
 
70
77
  it 'is true if the criterion is met once' do
71
- expect(["it's there"].at_least?(1) { |el| el == "it's there" }).to be_truthy
78
+ expect(["it's there", "it's there"]).to be_at_least(1) { |el| el == "it's there" }
72
79
  end
73
80
 
74
81
  it 'is true if all elements meet the criterion and the size is the given minimum number' do
75
- expect([1, 1, 1].at_least?(3) { |e| e == 1 }).to be_truthy
82
+ expect([1, 1, 1]).to be_at_least(3) { |e| e == 1 }
76
83
  end
77
84
 
78
85
  it 'is true if enough elements meet the criterion' do
79
- expect([1, 2, 4, 8].at_least?(2, &:even?)).to be_truthy
86
+ expect([1, 2, 4, 8].at_least(2, &:even?)).to be_truthy
80
87
  end
81
88
 
82
- it 'is true if there are enough elements to match' do
83
- r = Array.new(10) { |i| i }
84
- expect(r.at_least?(7) { |i| i > 2 }).to be_truthy
85
- expect(r.at_least?(8) { |i| i > 2 }).to be_falsey
89
+ it 'is true if there are enough matching elements' do
90
+ r = described_class.new(10) { |i| i }
91
+ expect(r).to be_at_least(7) { |i| i > 2 }
92
+ end
93
+
94
+ it 'is false if there are too few matching elements' do
95
+ r = described_class.new(10) { |i| i }
96
+ expect(r).not_to be_at_least(8) { |i| i > 2 }
86
97
  end
87
98
  end
88
99
 
89
- describe '#ocurrences_of' do
90
- context 'collection with content' do
91
- Set.include LimitDetectors
100
+ describe LimitDetectors, '#ocurrences_of' do
101
+ context 'when the collection has some content' do
102
+ Set.include described_class
92
103
  subject { Set.new([1, 2, 3, 4, 5, 6, 7]) }
93
104
 
94
- it('counts 3 even numbers') { expect(subject.occurrences_of(&:even?)).to be 3 }
95
- it('counts 4 odd numbers') { expect(subject.occurrences_of(&:odd?)).to be 4 }
96
- it('counts no number < 0') { expect(subject.occurrences_of { |e| e < 0 }).to be 0 }
105
+ it('counts 3 even numbers') { expect(subject.occurrences_of(&:even?)).to be 3 }
106
+ it('counts 4 odd numbers') { expect(subject.occurrences_of(&:odd?)).to be 4 }
107
+ it('counts no number < 0') { expect(subject.occurrences_of { |e| e < 0 }).to be 0 }
97
108
  it('counts 7 positive numbers') { expect(subject.occurrences_of { |e| e > 0 }).to be 7 }
98
109
  end
99
110
 
100
- context 'empty collection' do
111
+ context 'with an empty collection' do
101
112
  it 'counts 0 for any empty collection' do
102
113
  [[], Set.new, {}].each do |obj|
103
114
  expect(obj.occurrences_of { true }).to be(0), "Expected to count 0, for an empty #{obj.class}"
@@ -108,10 +119,10 @@ describe '#ocurrences_of' do
108
119
  it("doesn't return nil") { expect([1].occurrences_of {}).not_to be_nil }
109
120
  end
110
121
 
111
- describe "Using an object that doesn't respond to #inject" do
122
+ describe LimitDetectors, "Using an object that doesn't respond to #inject" do
112
123
  object = Object.new
113
- object.extend LimitDetectors
114
- it 'will raise an exception, if it\'s sent #at_most' do
124
+ object.extend described_class
125
+ it "raises an exception, if it's sent #at_most" do
115
126
  expect { object.at_most?(1, &:condition?) }.to raise_exception(NoMethodError, /undefined method .inject./)
116
127
  end
117
128
  end
@@ -130,8 +141,12 @@ end
130
141
 
131
142
  describe 'When the provided block raises an exception' do
132
143
  subject { [1] }
133
- it 'passes up the stack unchanged' do
144
+
145
+ it 'an exception in at_most? is passed up the stack' do
134
146
  expect { subject.at_most?(1) { raise ArgumentError, 'BoomError' } }.to raise_error(ArgumentError, 'BoomError')
147
+ end
148
+
149
+ it 'an exception in occurrences_of is passed up the stack' do
135
150
  expect { subject.occurrences_of { raise ArgumentError, 'BoomError' } }.to raise_error(ArgumentError, 'BoomError')
136
151
  end
137
152
  end
metadata CHANGED
@@ -1,149 +1,23 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: limit_detectors
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.8
4
+ version: 1.0.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stephan Kämper
8
- autorequire:
9
8
  bindir: bin
10
9
  cert_chain: []
11
- date: 2023-12-27 00:00:00.000000000 Z
12
- dependencies:
13
- - !ruby/object:Gem::Dependency
14
- name: bundler
15
- requirement: !ruby/object:Gem::Requirement
16
- requirements:
17
- - - ">="
18
- - !ruby/object:Gem::Version
19
- version: '0'
20
- type: :development
21
- prerelease: false
22
- version_requirements: !ruby/object:Gem::Requirement
23
- requirements:
24
- - - ">="
25
- - !ruby/object:Gem::Version
26
- version: '0'
27
- - !ruby/object:Gem::Dependency
28
- name: guard-rspec
29
- requirement: !ruby/object:Gem::Requirement
30
- requirements:
31
- - - ">="
32
- - !ruby/object:Gem::Version
33
- version: '0'
34
- type: :development
35
- prerelease: false
36
- version_requirements: !ruby/object:Gem::Requirement
37
- requirements:
38
- - - ">="
39
- - !ruby/object:Gem::Version
40
- version: '0'
41
- - !ruby/object:Gem::Dependency
42
- name: pry
43
- requirement: !ruby/object:Gem::Requirement
44
- requirements:
45
- - - "~>"
46
- - !ruby/object:Gem::Version
47
- version: 0.14.2
48
- type: :development
49
- prerelease: false
50
- version_requirements: !ruby/object:Gem::Requirement
51
- requirements:
52
- - - "~>"
53
- - !ruby/object:Gem::Version
54
- version: 0.14.2
55
- - !ruby/object:Gem::Dependency
56
- name: pry-doc
57
- requirement: !ruby/object:Gem::Requirement
58
- requirements:
59
- - - "~>"
60
- - !ruby/object:Gem::Version
61
- version: 1.4.0
62
- type: :development
63
- prerelease: false
64
- version_requirements: !ruby/object:Gem::Requirement
65
- requirements:
66
- - - "~>"
67
- - !ruby/object:Gem::Version
68
- version: 1.4.0
69
- - !ruby/object:Gem::Dependency
70
- name: rake
71
- requirement: !ruby/object:Gem::Requirement
72
- requirements:
73
- - - "~>"
74
- - !ruby/object:Gem::Version
75
- version: 13.0.6
76
- type: :development
77
- prerelease: false
78
- version_requirements: !ruby/object:Gem::Requirement
79
- requirements:
80
- - - "~>"
81
- - !ruby/object:Gem::Version
82
- version: 13.0.6
83
- - !ruby/object:Gem::Dependency
84
- name: rb-fsevent
85
- requirement: !ruby/object:Gem::Requirement
86
- requirements:
87
- - - ">="
88
- - !ruby/object:Gem::Version
89
- version: '0'
90
- type: :development
91
- prerelease: false
92
- version_requirements: !ruby/object:Gem::Requirement
93
- requirements:
94
- - - ">="
95
- - !ruby/object:Gem::Version
96
- version: '0'
97
- - !ruby/object:Gem::Dependency
98
- name: rspec
99
- requirement: !ruby/object:Gem::Requirement
100
- requirements:
101
- - - "~>"
102
- - !ruby/object:Gem::Version
103
- version: '3.12'
104
- type: :development
105
- prerelease: false
106
- version_requirements: !ruby/object:Gem::Requirement
107
- requirements:
108
- - - "~>"
109
- - !ruby/object:Gem::Version
110
- version: '3.12'
111
- - !ruby/object:Gem::Dependency
112
- name: terminal-notifier
113
- requirement: !ruby/object:Gem::Requirement
114
- requirements:
115
- - - ">="
116
- - !ruby/object:Gem::Version
117
- version: '0'
118
- type: :development
119
- prerelease: false
120
- version_requirements: !ruby/object:Gem::Requirement
121
- requirements:
122
- - - ">="
123
- - !ruby/object:Gem::Version
124
- version: '0'
125
- - !ruby/object:Gem::Dependency
126
- name: terminal-notifier-guard
127
- requirement: !ruby/object:Gem::Requirement
128
- requirements:
129
- - - ">="
130
- - !ruby/object:Gem::Version
131
- version: '0'
132
- type: :development
133
- prerelease: false
134
- version_requirements: !ruby/object:Gem::Requirement
135
- requirements:
136
- - - ">="
137
- - !ruby/object:Gem::Version
138
- version: '0'
139
- description: Some methods to detect whether an Enumerable object contains a constrained
140
- number of elements that match a given condition.
10
+ date: 1980-01-02 00:00:00.000000000 Z
11
+ dependencies: []
12
+ description: Detect if an Enumerable object contains at least/most x elements matching
13
+ a condition.
141
14
  email:
142
15
  - the.tester@seasidetesting.com
143
16
  executables: []
144
17
  extensions: []
145
18
  extra_rdoc_files: []
146
19
  files:
20
+ - ".codeclimate.yml"
147
21
  - ".github/workflows/codeql-analysis.yml"
148
22
  - ".github/workflows/ruby.yml"
149
23
  - ".gitignore"
@@ -164,12 +38,11 @@ files:
164
38
  - limit_detectors.gemspec
165
39
  - spec/limit_detectors_spec.rb
166
40
  - spec/spec_helper.rb
167
- homepage: ''
41
+ homepage: https://github.com/s2k/limit_detectors
168
42
  licenses:
169
43
  - MIT
170
44
  metadata:
171
45
  rubygems_mfa_required: 'true'
172
- post_install_message:
173
46
  rdoc_options: []
174
47
  require_paths:
175
48
  - lib
@@ -177,17 +50,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
177
50
  requirements:
178
51
  - - ">="
179
52
  - !ruby/object:Gem::Version
180
- version: '0'
53
+ version: 3.1.0
181
54
  required_rubygems_version: !ruby/object:Gem::Requirement
182
55
  requirements:
183
56
  - - ">="
184
57
  - !ruby/object:Gem::Version
185
58
  version: '0'
186
59
  requirements: []
187
- rubygems_version: 3.5.3
188
- signing_key:
60
+ rubygems_version: 3.7.2
189
61
  specification_version: 4
190
- summary: Detect certain conditions of elements of an Enumerable object
191
- test_files:
192
- - spec/limit_detectors_spec.rb
193
- - spec/spec_helper.rb
62
+ summary: Detect conditions of elements of an Enumerable object
63
+ test_files: []