limit_detectors 1.0.5 → 1.0.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Guardfile +44 -0
- data/README.md +15 -5
- data/checksums/limit_detectors-1.0.5.gem.sha512 +1 -0
- data/lib/limit_detectors/version.rb +1 -1
- data/limit_detectors.gemspec +5 -0
- metadata +61 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3677224e1354ba5859de92bc0b97c1099cb5c28e65f92351526a61b470209a2a
|
4
|
+
data.tar.gz: 3c38452128a1bc08491b007a76c745d865f5ffc77c0587953faca7ddddca2c39
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: cee66eda2505921f1512e8338a55dd2df34862f7dc1b14a63025d88617f9684c5367d3dbccff1b63e023e92679d23d224938c420087881b53bff908622e8564a
|
7
|
+
data.tar.gz: c7cb7be90f59fa5f1651305a4f50e2a420a490b1de17357c6a5b25d515d03319e5c4a2adb072f5b94e4f264f00e10b9c2a83fb38e14b571a06bd32f433cf6cad
|
data/Guardfile
ADDED
@@ -0,0 +1,44 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# A sample Guardfile
|
4
|
+
# More info at https://github.com/guard/guard#readme
|
5
|
+
|
6
|
+
## Uncomment and set this to only include directories you want to watch
|
7
|
+
# directories %w(app lib config test spec features) \
|
8
|
+
# .select{|d| Dir.exist?(d) ? d : UI.warning("Directory #{d} does not exist")}
|
9
|
+
|
10
|
+
## Note: if you are using the `directories` clause above and you are not
|
11
|
+
## watching the project directory ('.'), then you will want to move
|
12
|
+
## the Guardfile to a watched dir and symlink it back, e.g.
|
13
|
+
#
|
14
|
+
# $ mkdir config
|
15
|
+
# $ mv Guardfile config/
|
16
|
+
# $ ln -s config/Guardfile .
|
17
|
+
#
|
18
|
+
# and, you'll have to watch "config/Guardfile" instead of "Guardfile"
|
19
|
+
|
20
|
+
# NOTE: The cmd option is now required due to the increasing number of ways
|
21
|
+
# rspec may be run, below are examples of the most common uses.
|
22
|
+
# * bundler: 'bundle exec rspec'
|
23
|
+
# * bundler binstubs: 'bin/rspec'
|
24
|
+
# * spring: 'bin/rspec' (This will use spring if running and you have
|
25
|
+
# installed the spring binstubs per the docs)
|
26
|
+
# * zeus: 'zeus rspec' (requires the server to be started separately)
|
27
|
+
# * 'just' rspec: 'rspec'
|
28
|
+
|
29
|
+
guard :rspec, cmd: 'bundle exec rspec' do
|
30
|
+
require 'guard/rspec/dsl'
|
31
|
+
dsl = Guard::RSpec::Dsl.new(self)
|
32
|
+
|
33
|
+
# Feel free to open issues for suggestions and improvements
|
34
|
+
|
35
|
+
# RSpec files
|
36
|
+
rspec = dsl.rspec
|
37
|
+
watch(rspec.spec_helper) { rspec.spec_dir }
|
38
|
+
watch(rspec.spec_support) { rspec.spec_dir }
|
39
|
+
watch(rspec.spec_files)
|
40
|
+
|
41
|
+
# Ruby files
|
42
|
+
ruby = dsl.ruby
|
43
|
+
dsl.watch_spec_files_for(ruby.lib_files)
|
44
|
+
end
|
data/README.md
CHANGED
@@ -67,21 +67,19 @@ end
|
|
67
67
|
e = Example.new
|
68
68
|
e.extend LimitDetectors
|
69
69
|
|
70
|
-
|
71
70
|
puts e.at_least?(1) { |c| 'f' == c }
|
72
71
|
puts e.at_least?(1) { |c| 'b' == c }
|
73
72
|
puts e.at_most?(0) { |c| 'b' == c }
|
74
73
|
puts e.at_most?(42) { |c| 'b' == c }
|
75
74
|
```
|
76
75
|
|
77
|
-
|
78
76
|
## Compatibility
|
79
77
|
|
80
78
|
This gem is tested with these Ruby versions (MRI, unless JRuby):
|
81
79
|
|
82
|
-
- 2.7
|
83
|
-
- 3.0
|
84
|
-
- 3.1
|
80
|
+
- 2.7.x
|
81
|
+
- 3.0.x
|
82
|
+
- 3.1.x
|
85
83
|
|
86
84
|
as well as a current version of JRuby and TruffleRuby
|
87
85
|
|
@@ -95,6 +93,18 @@ as well as a current version of JRuby and TruffleRuby
|
|
95
93
|
|
96
94
|
A more detailed description is at https://opensource.com/article/19/7/create-pull-request-github
|
97
95
|
|
96
|
+
### Tip
|
97
|
+
|
98
|
+
After `bundle install` (or `update`) you can now use [`Guard`](https://github.com/guard/guard).
|
99
|
+
|
100
|
+
In the project directory run
|
101
|
+
|
102
|
+
```
|
103
|
+
bundle exec guard
|
104
|
+
```
|
105
|
+
|
106
|
+
Now, RSpec should run when files are saved (or changed otherwise).
|
107
|
+
Note though, that this may or may not work out-of-the-box on all operating systems.
|
98
108
|
|
99
109
|
### Reporting a bug
|
100
110
|
|
@@ -0,0 +1 @@
|
|
1
|
+
1239898f83c71b2c47cf6e8950369976824382a67cd53f3d99500fcb72af7ddaa5ffb8d42813e0c08a64087e51ede97e2a36d39d2442c67de4028fb9a1bdd434
|
data/limit_detectors.gemspec
CHANGED
@@ -20,10 +20,15 @@ Gem::Specification.new do |spec|
|
|
20
20
|
spec.require_paths = ['lib']
|
21
21
|
|
22
22
|
spec.add_development_dependency 'bundler'
|
23
|
+
spec.add_development_dependency 'guard-rspec'
|
23
24
|
spec.add_development_dependency 'pry', '~> 0.14.1'
|
24
25
|
spec.add_development_dependency 'pry-doc', '~> 1.2.0'
|
25
26
|
spec.add_development_dependency 'rake', '~> 13.0.6'
|
27
|
+
spec.add_development_dependency 'rb-fsevent'
|
26
28
|
spec.add_development_dependency 'rspec', '~> 3.10'
|
29
|
+
spec.add_development_dependency 'terminal-notifier'
|
30
|
+
spec.add_development_dependency 'terminal-notifier-guard'
|
31
|
+
|
27
32
|
spec.metadata = {
|
28
33
|
'rubygems_mfa_required' => 'true'
|
29
34
|
}
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: limit_detectors
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Stephan Kämper
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2022-01-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -24,6 +24,20 @@ dependencies:
|
|
24
24
|
- - ">="
|
25
25
|
- !ruby/object:Gem::Version
|
26
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'
|
27
41
|
- !ruby/object:Gem::Dependency
|
28
42
|
name: pry
|
29
43
|
requirement: !ruby/object:Gem::Requirement
|
@@ -66,6 +80,20 @@ dependencies:
|
|
66
80
|
- - "~>"
|
67
81
|
- !ruby/object:Gem::Version
|
68
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'
|
69
97
|
- !ruby/object:Gem::Dependency
|
70
98
|
name: rspec
|
71
99
|
requirement: !ruby/object:Gem::Requirement
|
@@ -80,6 +108,34 @@ dependencies:
|
|
80
108
|
- - "~>"
|
81
109
|
- !ruby/object:Gem::Version
|
82
110
|
version: '3.10'
|
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'
|
83
139
|
description: Some methods to detect whether an Enumerable object contains a constrained
|
84
140
|
number of elements that match a given condition.
|
85
141
|
email:
|
@@ -93,12 +149,14 @@ files:
|
|
93
149
|
- ".rspec"
|
94
150
|
- ".rubocop.yml"
|
95
151
|
- Gemfile
|
152
|
+
- Guardfile
|
96
153
|
- LICENSE.txt
|
97
154
|
- README.md
|
98
155
|
- Rakefile
|
99
156
|
- checksums/limit_detectors-1.0.2.gem.sha512
|
100
157
|
- checksums/limit_detectors-1.0.3.gem.sha512
|
101
158
|
- checksums/limit_detectors-1.0.4.gem.sha512
|
159
|
+
- checksums/limit_detectors-1.0.5.gem.sha512
|
102
160
|
- example/example.rb
|
103
161
|
- lib/limit_detectors.rb
|
104
162
|
- lib/limit_detectors/version.rb
|
@@ -125,7 +183,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
125
183
|
- !ruby/object:Gem::Version
|
126
184
|
version: '0'
|
127
185
|
requirements: []
|
128
|
-
rubygems_version: 3.3.
|
186
|
+
rubygems_version: 3.3.5
|
129
187
|
signing_key:
|
130
188
|
specification_version: 4
|
131
189
|
summary: Detect certain conditions of elements of an Enumerable object
|