kettle-soup-cover 1.0.4 → 1.0.6
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 +4 -4
- checksums.yaml.gz.sig +0 -0
- data/CHANGELOG.md +45 -1
- data/CODE_OF_CONDUCT.md +80 -29
- data/CONTRIBUTING.md +92 -33
- data/LICENSE.txt +1 -1
- data/README.md +321 -72
- data/SECURITY.md +12 -4
- data/lib/kettle/change.rb +39 -0
- data/lib/kettle/soup/cover/config.rb +10 -10
- data/lib/kettle/soup/cover/constants.rb +113 -0
- data/lib/kettle/soup/cover/filters/gt_line_filter.rb +0 -0
- data/lib/kettle/soup/cover/filters/lt_line_filter.rb +0 -0
- data/lib/kettle/soup/cover/loaders.rb +36 -0
- data/lib/kettle/soup/cover/rakelib/coverage.rake +20 -2
- data/lib/kettle/soup/cover/tasks.rb +0 -0
- data/lib/kettle/soup/cover/version.rb +1 -1
- data/lib/kettle/soup/cover.rb +23 -139
- data/lib/kettle-soup-cover.rb +5 -10
- data/sig/kettle/soup/cover/version.rbs +0 -0
- data/sig/kettle/soup/cover.rbs +1 -1
- data.tar.gz.sig +0 -0
- metadata +102 -62
- metadata.gz.sig +0 -0
data/README.md
CHANGED
@@ -6,12 +6,35 @@
|
|
6
6
|
|
7
7
|
# Kettle::Soup::Cover
|
8
8
|
|
9
|
-
|
9
|
+
[![Version][👽versioni]][👽version]
|
10
|
+
[![License: MIT][📄license-img]][📄license-ref]
|
11
|
+
[![Downloads Rank][👽dl-ranki]][👽dl-rank]
|
12
|
+
[![Open Source Helpers][👽oss-helpi]][👽oss-help]
|
13
|
+
[![Depfu][🔑depfui♻️]][🔑depfu]
|
14
|
+
[![CodeCov Test Coverage][🔑codecovi♻️]][🔑codecov]
|
15
|
+
[![Coveralls Test Coverage][🔑coveralls-img]][🔑coveralls]
|
16
|
+
[![CodeClimate Test Coverage][🔑cc-covi♻️]][🔑cc-cov]
|
17
|
+
[![Maintainability][🔑cc-mnti♻️]][🔑cc-mnt]
|
18
|
+
[![CI Heads][🚎3-hd-wfi]][🚎3-hd-wf]
|
19
|
+
[![CI Current][🚎11-c-wfi]][🚎11-c-wf]
|
20
|
+
[![CI Supported][🚎6-s-wfi]][🚎6-s-wf]
|
21
|
+
[![CI Legacy][🚎4-lg-wfi]][🚎4-lg-wf]
|
22
|
+
[![CI Unsupported][🚎7-us-wfi]][🚎7-us-wf]
|
23
|
+
[![CI Test Coverage][🚎2-cov-wfi]][🚎2-cov-wf]
|
24
|
+
[![CI Style][🚎5-st-wfi]][🚎5-st-wf]
|
10
25
|
|
11
|
-
|
12
|
-
where this library is considered a package of [SOUP](https://en.wikipedia.org/wiki/Software_of_unknown_pedigree).
|
26
|
+
---
|
13
27
|
|
14
|
-
|
28
|
+
[![Liberapay Goal Progress][⛳liberapay-img]][⛳liberapay]
|
29
|
+
[![Sponsor Me on Github][🖇sponsor-img]][🖇sponsor]
|
30
|
+
[![Buy me a coffee][🖇buyme-small-img]][🖇buyme]
|
31
|
+
[![Donate on Polar][🖇polar-img]][🖇polar]
|
32
|
+
[![Donate to my FLOSS or refugee efforts at ko-fi.com][🖇kofi-img]][🖇kofi]
|
33
|
+
[![Donate to my FLOSS or refugee efforts using Patreon][🖇patreon-img]][🖇patreon]
|
34
|
+
|
35
|
+
Four lines of code to get a configured, curated, opinionated, set of dependencies for Test Coverage.
|
36
|
+
|
37
|
+
Configured for what? To work out of the box on every CI. Batteries included.
|
15
38
|
|
16
39
|
One of the major benefits of using this library is not having to figure
|
17
40
|
out how to get multiple coverage output formats working. I did that for you,
|
@@ -20,48 +43,41 @@ and I got all of them working, at the same time together, or al la carte. Kum-ba
|
|
20
43
|
A quick shot of raw coverage power, straight to your brain:
|
21
44
|
|
22
45
|
```shell
|
23
|
-
export
|
46
|
+
export K_SOUP_COV_DO=true # Means you want code coverage
|
47
|
+
export K_SOUP_COV_FORMATTERS="html,tty" # Set to some slice of "html,xml,rcov,lcov,json,tty"
|
48
|
+
export K_SOUP_COV_MIN_BRANCH=53 # Means you want to enforce X% branch coverage
|
49
|
+
export K_SOUP_COV_MIN_HARD=true # Means you want the build to fail if the coverage thresholds are not met
|
50
|
+
export K_SOUP_COV_MIN_LINE=69 # Means you want to enforce X% line coverage
|
51
|
+
export MAX_ROWS=5 # Setting for simplecov-console gem for tty output, limits to the worst N rows of bad coverage
|
24
52
|
```
|
25
53
|
|
26
|
-
I hope I've piqued your interest.
|
27
|
-
|
28
|
-
## Support My Open Source Development
|
54
|
+
I hope I've piqued your interest enough to give it a ⭐️ if the forge you are on supports it.
|
29
55
|
|
30
|
-
<
|
56
|
+
<details>
|
57
|
+
<summary>What does the name mean?</summary>
|
31
58
|
|
32
|
-
|
33
|
-
<span class="badge-buymeacoffee">
|
34
|
-
[![Sponsor Me][🖇sponsor-img]][🖇sponsor]
|
35
|
-
<a href="https://ko-fi.com/O5O86SNP4" target='_blank' title="Donate to my FLOSS or refugee efforts at ko-fi.com"><img src="https://img.shields.io/badge/buy%20me%20coffee-donate-yellow.svg" alt="Buy Me Coffee donation button" /></a>
|
36
|
-
</span>
|
37
|
-
<span class="badge-patreon">
|
38
|
-
<a href="https://patreon.com/galtzo" title="Donate to my FLOSS or refugee efforts using Patreon"><img src="https://img.shields.io/badge/patreon-donate-yellow.svg" alt="Patreon donate button" /></a>
|
39
|
-
</span>
|
59
|
+
A Covered Kettle of SOUP (Software of Unknown Provenance)
|
40
60
|
|
41
|
-
|
61
|
+
The name is derived in part from the medical devices field,
|
62
|
+
where this library is considered a package of [SOUP](https://en.wikipedia.org/wiki/Software_of_unknown_pedigree).
|
42
63
|
|
43
|
-
|
44
|
-
[![Follow Me on X][🐦twitter-img]][🐦twitter]
|
45
|
-
[![Follow Me on LinkedIn][🖇linkedin-img]][🖇linkedin]
|
46
|
-
[![Subscribe to my Rubygems updates][💎rubygems-img]][💎rubygems]
|
47
|
-
[![My Blog][🚎blog-img]][🚎blog]
|
64
|
+
</details>
|
48
65
|
|
49
|
-
|
66
|
+
## 💡 Info you can shake a stick at
|
50
67
|
|
51
|
-
[
|
52
|
-
|
53
|
-
[
|
54
|
-
[
|
55
|
-
[
|
56
|
-
[
|
57
|
-
[
|
58
|
-
[
|
59
|
-
[
|
60
|
-
[
|
61
|
-
[
|
62
|
-
[🚎blog-img]: https://img.shields.io/badge/blog-railsbling-brightgreen.svg?style=flat
|
68
|
+
| Tokens to Remember | [![Gem name][⛳️name-img]][⛳️gem-name] [![Gem namespace][⛳️namespace-img]][⛳️gem-namespace] |
|
69
|
+
|-------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
70
|
+
| Works with MRI Ruby 3 | [![Ruby 3.0 Compat][💎ruby-3.0i]][🚎4-lg-wf] [![Ruby 3.1 Compat][💎ruby-3.1i]][🚎6-s-wf] [![Ruby 3.2 Compat][💎ruby-3.2i]][🚎6-s-wf] [![Ruby 3.3 Compat][💎ruby-3.3i]][🚎6-s-wf] [![Ruby 3.4 Compat][💎ruby-c-i]][🚎11-c-wf] [![Ruby HEAD Compat][💎ruby-headi]][🚎3-hd-wf] |
|
71
|
+
| Works with MRI Ruby 2 | [![Ruby 2.7 Compat][💎ruby-2.7i]][🚎7-us-wf] |
|
72
|
+
| Source | [![Source on GitLab.com][📜src-gl-img]][📜src-gl] [![Source on CodeBerg.org][📜src-cb-img]][📜src-cb] [![Source on Github.com][📜src-gh-img]][📜src-gh] [![The best SHA: dQw4w9WgXcQ!][🧮kloc-img]][🧮kloc] |
|
73
|
+
| Documentation | [![Current release on RubyDoc.info][📜docs-cr-rd-img]][🚎yard-current] [![HEAD on RubyDoc.info][📜docs-head-rd-img]][🚎yard-head] [![BDFL Blog][🚂bdfl-blog-img]][🚂bdfl-blog] [![Wiki][📜wiki-img]][📜wiki] |
|
74
|
+
| Compliance | [![License: MIT][📄license-img]][📄license-ref] [![📄ilo-declaration-img]][📄ilo-declaration] [![Security Policy][🔐security-img]][🔐security] [![CodeQL][🖐codeQL-img]][🖐codeQL] [![Contributor Covenant 2.1][🪇conduct-img]][🪇conduct] [![SemVer 2.0.0][📌semver-img]][📌semver] [![Keep-A-Changelog 1.0.0][📗keep-changelog-img]][📗keep-changelog] [![Gitmoji Commits][📌gitmoji-img]][📌gitmoji] |
|
75
|
+
| Expert 1:1 Support | [![Get help from me on Upwork][👨🏼🏫expsup-upwork-img]][👨🏼🏫expsup-upwork] `or` [![Get help from me on Codementor][👨🏼🏫expsup-codementor-img]][👨🏼🏫expsup-codementor] |
|
76
|
+
| Enterprise Support | [![Get help from me on Tidelift][🏙️entsup-tidelift-img]][🏙️entsup-tidelift]<br/>💡Subscribe for support guarantees covering _all_ FLOSS dependencies!<br/>💡Tidelift is part of [Sonar][🏙️entsup-tidelift-sonar]!<br/>💡Tidelift pays maintainers to maintain the software you depend on!<br/>📊`@`Pointy Haired Boss: An [enterprise support][🏙️entsup-tidelift] subscription is "[never gonna let you down][🧮kloc]", and *supports* open source maintainers! |
|
77
|
+
| Comrade BDFL 🎖️ | [![Follow Me on LinkedIn][💖🖇linkedin-img]][💖🖇linkedin] [![Follow Me on Ruby.Social][💖🐘ruby-mast-img]][💖🐘ruby-mast] [![Follow Me on Bluesky][💖🦋bluesky-img]][💖🦋bluesky] [![Contact BDFL][🚂bdfl-contact-img]][🚂bdfl-contact] [![My technical writing][💖💁🏼♂️devto-img]][💖💁🏼♂️devto] |
|
78
|
+
| `...` 💖 | [![Find Me on WellFound:][💖✌️wellfound-img]][💖✌️wellfound] [![Find Me on CrunchBase][💖💲crunchbase-img]][💖💲crunchbase] [![My LinkTree][💖🌳linktree-img]][💖🌳linktree] [![More About Me][💖💁🏼♂️aboutme-img]][💖💁🏼♂️aboutme] [🧊][💖🧊berg] [🐙][💖🐙hub] [🛖][💖🛖hut] [🧪][💖🧪lab] |
|
63
79
|
|
64
|
-
## Installation
|
80
|
+
## ✨ Installation
|
65
81
|
|
66
82
|
Install the gem and add to the application's Gemfile by executing:
|
67
83
|
|
@@ -71,24 +87,53 @@ If bundler is not being used to manage dependencies, install the gem by executin
|
|
71
87
|
|
72
88
|
$ gem install kettle-soup-cover
|
73
89
|
|
74
|
-
|
90
|
+
### 🔒 Secure Installation
|
91
|
+
|
92
|
+
`kettle-soup-cover` is cryptographically signed. To be sure the gem you install hasn’t been tampered with:
|
93
|
+
|
94
|
+
Add my public key (if you haven’t already, expires 2045-05-04) as a trusted certificate:
|
95
|
+
|
96
|
+
```shell
|
97
|
+
gem cert --add <(curl -Ls https://raw.github.com/kettle-rb/kettle-soup-cover/main/certs/pboling.pem)
|
98
|
+
```
|
99
|
+
|
100
|
+
You only need to do that once. Then proceed to install with:
|
101
|
+
|
102
|
+
```shell
|
103
|
+
gem install kettle-soup-cover -P MediumSecurity
|
104
|
+
```
|
105
|
+
|
106
|
+
The MediumSecurity trust profile will verify signed gems, but allow the installation of unsigned dependencies.
|
107
|
+
|
108
|
+
This is necessary because not all of `kettle-soup-cover`’s dependencies are signed, so we cannot use HighSecurity.
|
109
|
+
|
110
|
+
If you want to up your security game full-time:
|
111
|
+
|
112
|
+
```shell
|
113
|
+
bundle config set --global trust-policy MediumSecurity
|
114
|
+
```
|
115
|
+
|
116
|
+
NOTE: Be prepared to track down certs for signed gems and add them the same way you added mine.
|
75
117
|
|
76
|
-
|
118
|
+
## 🔧 Basic Usage
|
119
|
+
|
120
|
+
In your `spec/spec_helper.rb`, just prior to loading the library under test, add 2 lines of code:
|
77
121
|
|
78
122
|
```ruby
|
79
123
|
# This does not require "simplecov",
|
80
|
-
# because that has a side
|
124
|
+
# because that has a side effect of running `.simplecov`
|
81
125
|
require "kettle-soup-cover"
|
82
126
|
|
83
127
|
# Later in your spec setup, do this;
|
84
128
|
require "simplecov" if Kettle::Soup::Cover::DO_COV
|
85
129
|
```
|
86
130
|
|
87
|
-
In your `.simplecov` file:
|
131
|
+
In your `.simplecov` file, add 2 lines of code:
|
88
132
|
|
89
133
|
```ruby
|
90
134
|
require "kettle/soup/cover/config"
|
91
|
-
|
135
|
+
# you could do this somewhere else, up to you, but you do have to do it somewhere
|
136
|
+
SimpleCov.start
|
92
137
|
```
|
93
138
|
|
94
139
|
See [Advanced Usage](#advanced-usage) below for more info,
|
@@ -104,10 +149,10 @@ That's it!
|
|
104
149
|
### Rakefile
|
105
150
|
|
106
151
|
You'll need to have your `test` task defined.
|
107
|
-
If you use `spec` instead, you can
|
152
|
+
If you use `spec` instead, you can make it a pre-requisite of the `test` task with:
|
108
153
|
|
109
154
|
```ruby
|
110
|
-
desc "
|
155
|
+
desc "run spec task with test task"
|
111
156
|
task test: :spec
|
112
157
|
```
|
113
158
|
|
@@ -153,39 +198,91 @@ K_SOUP_COV_MIN_HARD
|
|
153
198
|
K_SOUP_COV_MIN_LINE
|
154
199
|
K_SOUP_COV_MULTI_FORMATTERS
|
155
200
|
K_SOUP_COV_PREFIX
|
201
|
+
K_SOUP_COV_OPEN_BIN
|
156
202
|
K_SOUP_COV_USE_MERGING
|
157
203
|
K_SOUP_COV_VERBOSE
|
158
204
|
```
|
159
205
|
|
160
|
-
Additionally some of the included gems, like [`simplecov-console`][simplecov-console],
|
206
|
+
Additionally, some of the included gems, like [`simplecov-console`][simplecov-console],
|
161
207
|
have their own complete suite of ENV variables you can configure.
|
162
208
|
|
163
209
|
[env-constants]: /lib/kettle/soup/cover.rb
|
164
210
|
[simplecov-console]: https://github.com/chetan/simplecov-console#options
|
165
211
|
|
166
|
-
|
212
|
+
### 🚀 Release Instructions
|
213
|
+
|
214
|
+
See [CONTRIBUTING.md][🤝contributing].
|
215
|
+
|
216
|
+
## 🔐 Security
|
217
|
+
|
218
|
+
See [SECURITY.md][🔐security].
|
219
|
+
|
220
|
+
## 🤝 Contributing
|
221
|
+
|
222
|
+
If you need some ideas of where to help, you could work on adding more code coverage,
|
223
|
+
or if it is already 💯 (see [below](#code-coverage)) check TODOs (see [below](#todos)),
|
224
|
+
or check [issues][🤝issues], or [PRs][🤝pulls],
|
225
|
+
or use the gem and think about how it could be better.
|
226
|
+
|
227
|
+
We [![Keep A Changelog][📗keep-changelog-img]][📗keep-changelog] so if you make changes, remember to update it.
|
228
|
+
|
229
|
+
See [CONTRIBUTING.md][🤝contributing] for more detailed instructions.
|
230
|
+
|
231
|
+
### Code Coverage
|
232
|
+
|
233
|
+
[![Coverage Graph][🔑codecov-g♻️]][🔑codecov]
|
234
|
+
|
235
|
+
### 🪇 Code of Conduct
|
236
|
+
|
237
|
+
Everyone interacting in this project's codebases, issue trackers,
|
238
|
+
chat rooms and mailing lists is expected to follow the [![Contributor Covenant 2.1][🪇conduct-img]][🪇conduct].
|
167
239
|
|
168
|
-
|
240
|
+
## 🌈 Contributors
|
169
241
|
|
170
|
-
|
242
|
+
[![Contributors][🖐contributors-img]][🖐contributors]
|
171
243
|
|
172
|
-
|
244
|
+
Made with [contributors-img][🖐contrib-rocks].
|
173
245
|
|
174
|
-
|
246
|
+
Also see GitLab Contributors: [https://gitlab.com/kettle-rb/kettle-soup-cover/-/graphs/main][🚎contributors-gl]
|
175
247
|
|
176
|
-
##
|
248
|
+
## ⭐️ Star History
|
177
249
|
|
178
|
-
|
250
|
+
<a href="https://star-history.com/#kettle-rb/kettle-soup-cover&Date">
|
251
|
+
<picture>
|
252
|
+
<source media="(prefers-color-scheme: dark)" srcset="https://api.star-history.com/svg?repos=kettle-rb/kettle-soup-cover&type=Date&theme=dark" />
|
253
|
+
<source media="(prefers-color-scheme: light)" srcset="https://api.star-history.com/svg?repos=kettle-rb/kettle-soup-cover&type=Date" />
|
254
|
+
<img alt="Star History Chart" src="https://api.star-history.com/svg?repos=kettle-rb/kettle-soup-cover&type=Date" />
|
255
|
+
</picture>
|
256
|
+
</a>
|
179
257
|
|
180
|
-
## Versioning
|
258
|
+
## 📌 Versioning
|
181
259
|
|
182
|
-
This
|
183
|
-
|
184
|
-
|
185
|
-
|
260
|
+
This Library adheres to [![Semantic Versioning 2.0.0][📌semver-img]][📌semver].
|
261
|
+
Violations of this scheme should be reported as bugs.
|
262
|
+
Specifically, if a minor or patch version is released that breaks backward compatibility,
|
263
|
+
a new version should be immediately released that restores compatibility.
|
264
|
+
Breaking changes to the public API will only be introduced with new major versions.
|
186
265
|
|
187
|
-
|
188
|
-
|
266
|
+
### 📌 Is "Platform Support" part of the public API?
|
267
|
+
|
268
|
+
Yes. But I'm obligated to include notes...
|
269
|
+
|
270
|
+
SemVer should, but doesn't explicitly, say that dropping support for specific Platforms
|
271
|
+
is a *breaking change* to an API.
|
272
|
+
It is obvious to many, but not all, and since the spec is silent, the bike shedding is endless.
|
273
|
+
|
274
|
+
> dropping support for a platform is both obviously and objectively a breaking change
|
275
|
+
|
276
|
+
- Jordan Harband (@ljharb, maintainer of SemVer) [in SemVer issue 716][📌semver-breaking]
|
277
|
+
|
278
|
+
To get a better understanding of how SemVer is intended to work over a project's lifetime,
|
279
|
+
read this article from the creator of SemVer:
|
280
|
+
|
281
|
+
- ["Major Version Numbers are Not Sacred"][📌major-versions-not-sacred]
|
282
|
+
|
283
|
+
As a result of this policy, and the interpretive lens used by the maintainer,
|
284
|
+
you can (and should) specify a dependency on these libraries using
|
285
|
+
the [Pessimistic Version Constraint][📌pvc] with two digits of precision.
|
189
286
|
|
190
287
|
For example:
|
191
288
|
|
@@ -193,18 +290,170 @@ For example:
|
|
193
290
|
spec.add_dependency("kettle-soup-cover", "~> 1.0")
|
194
291
|
```
|
195
292
|
|
196
|
-
|
293
|
+
See [CHANGELOG.md][📌changelog] for list of releases.
|
294
|
+
|
295
|
+
## 📄 License
|
197
296
|
|
198
297
|
The gem is available as open source under the terms of
|
199
|
-
the [MIT License][license] [![License: MIT][license-img]][license-ref].
|
200
|
-
See [LICENSE][license] for the official [Copyright Notice][copyright-notice-explainer].
|
201
|
-
|
202
|
-
|
203
|
-
|
204
|
-
|
205
|
-
|
206
|
-
|
207
|
-
|
208
|
-
|
209
|
-
|
210
|
-
|
298
|
+
the [MIT License][📄license] [![License: MIT][📄license-img]][📄license-ref].
|
299
|
+
See [LICENSE.txt][📄license] for the official [Copyright Notice][📄copyright-notice-explainer].
|
300
|
+
|
301
|
+
### © Copyright
|
302
|
+
|
303
|
+
<p>
|
304
|
+
Copyright (c) 2023 - 2025 Peter H. Boling,
|
305
|
+
<a href="https://railsbling.com">
|
306
|
+
RailsBling.com
|
307
|
+
<picture>
|
308
|
+
<img alt="Rails Bling" height="20" src="https://railsbling.com/images/logos/RailsBling-TrainLogo.svg" />
|
309
|
+
</picture>
|
310
|
+
</a>
|
311
|
+
</p>
|
312
|
+
|
313
|
+
## 🤑 One more thing
|
314
|
+
|
315
|
+
You made it to the bottom of the page,
|
316
|
+
so perhaps you'll indulge me for another 20 seconds.
|
317
|
+
I maintain many dozens of gems, including this one,
|
318
|
+
because I want Ruby to be a great place for people to solve problems, big and small.
|
319
|
+
Please consider supporting my efforts via the giant yellow link below,
|
320
|
+
or one of the others at the head of this README.
|
321
|
+
|
322
|
+
[![Buy me a latte][🖇buyme-img]][🖇buyme]
|
323
|
+
|
324
|
+
[✇bundle-group-pattern]: https://gist.github.com/pboling/4564780
|
325
|
+
[⛳️gem-namespace]: https://github.com/kettle-rb/kettle-soup-cover/blob/main/lib/masq.rb
|
326
|
+
[⛳️namespace-img]: https://img.shields.io/badge/namespace-Kettle%3A%3ASoup%3A%3ACover-brightgreen.svg?style=flat&logo=ruby&logoColor=white
|
327
|
+
[⛳️gem-name]: https://rubygems.org/gems/kettle-soup-cover
|
328
|
+
[⛳️name-img]: https://img.shields.io/badge/name-kettle--soup--cover-brightgreen.svg?style=flat&logo=rubygems&logoColor=red
|
329
|
+
[🚂bdfl-blog]: http://www.railsbling.com/tags/kettle-soup-cover
|
330
|
+
[🚂bdfl-blog-img]: https://img.shields.io/badge/blog-railsbling-0093D0.svg?style=for-the-badge&logo=rubyonrails&logoColor=orange
|
331
|
+
[🚂bdfl-contact]: http://www.railsbling.com/contact
|
332
|
+
[🚂bdfl-contact-img]: https://img.shields.io/badge/Contact-BDFL-0093D0.svg?style=flat&logo=rubyonrails&logoColor=red
|
333
|
+
[💖🖇linkedin]: http://www.linkedin.com/in/peterboling
|
334
|
+
[💖🖇linkedin-img]: https://img.shields.io/badge/PeterBoling-LinkedIn-0B66C2?style=flat&logo=newjapanprowrestling
|
335
|
+
[💖✌️wellfound]: https://angel.co/u/peter-boling
|
336
|
+
[💖✌️wellfound-img]: https://img.shields.io/badge/peter--boling-orange?style=flat&logo=wellfound
|
337
|
+
[💖💲crunchbase]: https://www.crunchbase.com/person/peter-boling
|
338
|
+
[💖💲crunchbase-img]: https://img.shields.io/badge/peter--boling-purple?style=flat&logo=crunchbase
|
339
|
+
[💖🐘ruby-mast]: https://ruby.social/@galtzo
|
340
|
+
[💖🐘ruby-mast-img]: https://img.shields.io/mastodon/follow/109447111526622197?domain=https%3A%2F%2Fruby.social&style=flat&logo=mastodon&label=Ruby%20%40galtzo
|
341
|
+
[💖🦋bluesky]: https://galtzo.bsky.social
|
342
|
+
[💖🦋bluesky-img]: https://img.shields.io/badge/@galtzo.bsky.social-0285FF?style=flat&logo=bluesky&logoColor=white
|
343
|
+
[💖🌳linktree]: https://linktr.ee/galtzo
|
344
|
+
[💖🌳linktree-img]: https://img.shields.io/badge/galtzo-purple?style=flat&logo=linktree
|
345
|
+
[💖💁🏼♂️devto]: https://dev.to/galtzo
|
346
|
+
[💖💁🏼♂️devto-img]: https://img.shields.io/badge/dev.to-0A0A0A?style=flat&logo=devdotto&logoColor=white
|
347
|
+
[💖💁🏼♂️aboutme]: https://about.me/peter.boling
|
348
|
+
[💖💁🏼♂️aboutme-img]: https://img.shields.io/badge/about.me-0A0A0A?style=flat&logo=aboutme&logoColor=white
|
349
|
+
[💖🧊berg]: https://codeberg.org/pboling
|
350
|
+
[💖🐙hub]: https://github.org/pboling
|
351
|
+
[💖🛖hut]: https://sr.ht/~galtzo/
|
352
|
+
[💖🧪lab]: https://gitlab.com/pboling
|
353
|
+
[👨🏼🏫expsup-upwork]: https://www.upwork.com/freelancers/~014942e9b056abdf86?mp_source=share
|
354
|
+
[👨🏼🏫expsup-upwork-img]: https://img.shields.io/badge/UpWork-13544E?style=for-the-badge&logo=Upwork&logoColor=white
|
355
|
+
[👨🏼🏫expsup-codementor]: https://www.codementor.io/peterboling?utm_source=github&utm_medium=button&utm_term=peterboling&utm_campaign=github
|
356
|
+
[👨🏼🏫expsup-codementor-img]: https://img.shields.io/badge/CodeMentor-Get_Help-1abc9c?style=for-the-badge&logo=CodeMentor&logoColor=white
|
357
|
+
[🏙️entsup-tidelift]: https://tidelift.com/subscription
|
358
|
+
[🏙️entsup-tidelift-img]: https://img.shields.io/badge/Tidelift_and_Sonar-Enterprise_Support-FD3456?style=for-the-badge&logo=sonar&logoColor=white
|
359
|
+
[🏙️entsup-tidelift-sonar]: https://blog.tidelift.com/tidelift-joins-sonar
|
360
|
+
[💁🏼♂️peterboling]: http://www.peterboling.com
|
361
|
+
[🚂railsbling]: http://www.railsbling.com
|
362
|
+
[📜src-gl-img]: https://img.shields.io/badge/GitLab-FBA326?style=for-the-badge&logo=Gitlab&logoColor=orange
|
363
|
+
[📜src-gl]: https://gitlab.com/kettle-rb/kettle-soup-cover/
|
364
|
+
[📜src-cb-img]: https://img.shields.io/badge/CodeBerg-4893CC?style=for-the-badge&logo=CodeBerg&logoColor=blue
|
365
|
+
[📜src-cb]: https://codeberg.org/kettle-rb/kettle-soup-cover
|
366
|
+
[📜src-gh-img]: https://img.shields.io/badge/GitHub-238636?style=for-the-badge&logo=Github&logoColor=green
|
367
|
+
[📜src-gh]: https://github.com/kettle-rb/kettle-soup-cover
|
368
|
+
[📜docs-cr-rd-img]: https://img.shields.io/badge/RubyDoc-Current_Release-943CD2?style=for-the-badge&logo=readthedocs&logoColor=white
|
369
|
+
[📜docs-head-rd-img]: https://img.shields.io/badge/RubyDoc-HEAD-943CD2?style=for-the-badge&logo=readthedocs&logoColor=white
|
370
|
+
[📜wiki]: https://gitlab.com/kettle-rb/kettle-soup-cover/-/wikis/home
|
371
|
+
[📜wiki-img]: https://img.shields.io/badge/wiki-examples-943CD2.svg?style=for-the-badge&logo=Wiki&logoColor=white
|
372
|
+
[👽dl-rank]: https://rubygems.org/gems/kettle-soup-cover
|
373
|
+
[👽dl-ranki]: https://img.shields.io/gem/rd/kettle-soup-cover.svg
|
374
|
+
[👽oss-help]: https://www.codetriage.com/kettle-rb/kettle-soup-cover
|
375
|
+
[👽oss-helpi]: https://www.codetriage.com/kettle-rb/kettle-soup-cover/badges/users.svg
|
376
|
+
[👽version]: https://rubygems.org/gems/kettle-soup-cover
|
377
|
+
[👽versioni]: https://img.shields.io/gem/v/kettle-soup-cover.svg
|
378
|
+
[🔑cc-mnt]: https://qlty.sh/gh/kettle-rb/projects/kettle-soup-cover
|
379
|
+
[🔑cc-mnti♻️]: https://qlty.sh/badges/75db1a51-b8ab-423a-b396-8b518067d8c3/maintainability.svg
|
380
|
+
[🔑cc-cov]: https://qlty.sh/gh/kettle-rb/projects/kettle-soup-cover
|
381
|
+
[🔑cc-covi♻️]: https://qlty.sh/badges/75db1a51-b8ab-423a-b396-8b518067d8c3/test_coverage.svg
|
382
|
+
[🔑codecov]: https://codecov.io/gh/kettle-rb/kettle-soup-cover
|
383
|
+
[🔑codecovi♻️]: https://codecov.io/gh/kettle-rb/kettle-soup-cover/branch/main/graph/badge.svg?token=0X5VEW9USD
|
384
|
+
[🔑coveralls]: https://coveralls.io/github/kettle-rb/kettle-soup-cover?branch=main
|
385
|
+
[🔑coveralls-img]: https://coveralls.io/repos/github/kettle-rb/kettle-soup-cover/badge.svg?branch=main
|
386
|
+
[🔑depfu]: https://depfu.com/github/kettle-rb/kettle-soup-cover?project_id=60302
|
387
|
+
[🔑depfui♻️]: https://badges.depfu.com/badges/71e1a65eafef1b12a044bf04bbea4f90/count.svg
|
388
|
+
[🖐codeQL]: https://github.com/kettle-rb/kettle-soup-cover/security/code-scanning
|
389
|
+
[🖐codeQL-img]: https://github.com/kettle-rb/kettle-soup-cover/actions/workflows/codeql-analysis.yml/badge.svg
|
390
|
+
[🚎1-an-wf]: https://github.com/kettle-rb/kettle-soup-cover/actions/workflows/ancient.yml
|
391
|
+
[🚎1-an-wfi]: https://github.com/kettle-rb/kettle-soup-cover/actions/workflows/ancient.yml/badge.svg
|
392
|
+
[🚎2-cov-wf]: https://github.com/kettle-rb/kettle-soup-cover/actions/workflows/coverage.yml
|
393
|
+
[🚎2-cov-wfi]: https://github.com/kettle-rb/kettle-soup-cover/actions/workflows/coverage.yml/badge.svg
|
394
|
+
[🚎3-hd-wf]: https://github.com/kettle-rb/kettle-soup-cover/actions/workflows/heads.yml
|
395
|
+
[🚎3-hd-wfi]: https://github.com/kettle-rb/kettle-soup-cover/actions/workflows/heads.yml/badge.svg
|
396
|
+
[🚎4-lg-wf]: https://github.com/kettle-rb/kettle-soup-cover/actions/workflows/legacy.yml
|
397
|
+
[🚎4-lg-wfi]: https://github.com/kettle-rb/kettle-soup-cover/actions/workflows/legacy.yml/badge.svg
|
398
|
+
[🚎5-st-wf]: https://github.com/kettle-rb/kettle-soup-cover/actions/workflows/style.yml
|
399
|
+
[🚎5-st-wfi]: https://github.com/kettle-rb/kettle-soup-cover/actions/workflows/style.yml/badge.svg
|
400
|
+
[🚎6-s-wf]: https://github.com/kettle-rb/kettle-soup-cover/actions/workflows/supported.yml
|
401
|
+
[🚎6-s-wfi]: https://github.com/kettle-rb/kettle-soup-cover/actions/workflows/supported.yml/badge.svg
|
402
|
+
[🚎7-us-wf]: https://github.com/kettle-rb/kettle-soup-cover/actions/workflows/unsupported.yml
|
403
|
+
[🚎7-us-wfi]: https://github.com/kettle-rb/kettle-soup-cover/actions/workflows/unsupported.yml/badge.svg
|
404
|
+
[🚎8-ho-wf]: https://github.com/kettle-rb/kettle-soup-cover/actions/workflows/hoary.yml
|
405
|
+
[🚎8-ho-wfi]: https://github.com/kettle-rb/kettle-soup-cover/actions/workflows/hoary.yml/badge.svg
|
406
|
+
[🚎11-c-wf]: https://github.com/kettle-rb/kettle-soup-cover/actions/workflows/current.yml
|
407
|
+
[🚎11-c-wfi]: https://github.com/kettle-rb/kettle-soup-cover/actions/workflows/current.yml/badge.svg
|
408
|
+
[⛳liberapay-img]: https://img.shields.io/liberapay/goal/pboling.svg?logo=liberapay
|
409
|
+
[⛳liberapay]: https://liberapay.com/pboling/donate
|
410
|
+
[🖇sponsor-img]: https://img.shields.io/badge/Sponsor_Me!-pboling.svg?style=social&logo=github
|
411
|
+
[🖇sponsor]: https://github.com/sponsors/pboling
|
412
|
+
[🖇polar-img]: https://img.shields.io/badge/polar-donate-yellow.svg
|
413
|
+
[🖇polar]: https://polar.sh/pboling
|
414
|
+
[🖇kofi-img]: https://img.shields.io/badge/a_more_different_coffee-✓-yellow.svg
|
415
|
+
[🖇kofi]: https://ko-fi.com/O5O86SNP4
|
416
|
+
[🖇patreon-img]: https://img.shields.io/badge/patreon-donate-yellow.svg
|
417
|
+
[🖇patreon]: https://patreon.com/galtzo
|
418
|
+
[🖇buyme-img]: https://img.buymeacoffee.com/button-api/?text=Buy%20me%20a%20latte&emoji=&slug=pboling&button_colour=FFDD00&font_colour=000000&font_family=Cookie&outline_colour=000000&coffee_colour=ffffff
|
419
|
+
[🖇buyme]: https://www.buymeacoffee.com/pboling
|
420
|
+
[🖇buyme-small-img]: https://img.shields.io/badge/buy_me_a_coffee-✓-yellow.svg?style=flat
|
421
|
+
[💎ruby-2.7i]: https://img.shields.io/badge/Ruby-2.7-DF00CA?style=for-the-badge&logo=ruby&logoColor=white
|
422
|
+
[💎ruby-3.0i]: https://img.shields.io/badge/Ruby-3.0-CC342D?style=for-the-badge&logo=ruby&logoColor=white
|
423
|
+
[💎ruby-3.1i]: https://img.shields.io/badge/Ruby-3.1-CC342D?style=for-the-badge&logo=ruby&logoColor=white
|
424
|
+
[💎ruby-3.2i]: https://img.shields.io/badge/Ruby-3.2-CC342D?style=for-the-badge&logo=ruby&logoColor=white
|
425
|
+
[💎ruby-3.3i]: https://img.shields.io/badge/Ruby-3.3-CC342D?style=for-the-badge&logo=ruby&logoColor=white
|
426
|
+
[💎ruby-c-i]: https://img.shields.io/badge/Ruby-current-CC342D?style=for-the-badge&logo=ruby&logoColor=green
|
427
|
+
[💎ruby-headi]: https://img.shields.io/badge/Ruby-HEAD-CC342D?style=for-the-badge&logo=ruby&logoColor=blue
|
428
|
+
[🤝issues]: https://github.com/kettle-rb/kettle-soup-cover/issues
|
429
|
+
[🤝pulls]: https://github.com/kettle-rb/kettle-soup-cover/pulls
|
430
|
+
[🤝contributing]: CONTRIBUTING.md
|
431
|
+
[🔑codecov-g♻️]: https://codecov.io/gh/kettle-rb/kettle-soup-cover/graphs/tree.svg?token=0X5VEW9USD
|
432
|
+
[🖐contrib-rocks]: https://contrib.rocks
|
433
|
+
[🖐contributors]: https://github.com/kettle-rb/kettle-soup-cover/graphs/contributors
|
434
|
+
[🖐contributors-img]: https://contrib.rocks/image?repo=kettle-rb/kettle-soup-cover
|
435
|
+
[🚎contributors-gl]: https://gitlab.com/kettle-rb/kettle-soup-cover/-/graphs/main
|
436
|
+
[🪇conduct]: CODE_OF_CONDUCT.md
|
437
|
+
[🪇conduct-img]: https://img.shields.io/badge/Contributor_Covenant-2.1-4baaaa.svg
|
438
|
+
[📌pvc]: http://guides.rubygems.org/patterns/#pessimistic-version-constraint
|
439
|
+
[📌semver]: https://semver.org/spec/v2.0.0.html
|
440
|
+
[📌semver-img]: https://img.shields.io/badge/semver-2.0.0-FFDD67.svg?style=flat
|
441
|
+
[📌semver-breaking]: https://github.com/semver/semver/issues/716#issuecomment-869336139
|
442
|
+
[📌major-versions-not-sacred]: https://tom.preston-werner.com/2022/05/23/major-version-numbers-are-not-sacred.html
|
443
|
+
[📌changelog]: CHANGELOG.md
|
444
|
+
[📗keep-changelog]: https://keepachangelog.com/en/1.0.0/
|
445
|
+
[📗keep-changelog-img]: https://img.shields.io/badge/keep--a--changelog-1.0.0-FFDD67.svg?style=flat
|
446
|
+
[📌gitmoji]:https://gitmoji.dev
|
447
|
+
[📌gitmoji-img]:https://img.shields.io/badge/gitmoji-%20😜%20😍-FFDD67.svg?style=flat-square
|
448
|
+
[🧮kloc]: https://www.youtube.com/watch?v=dQw4w9WgXcQ
|
449
|
+
[🧮kloc-img]: https://img.shields.io/badge/KLOC-0.137-FFDD67.svg?style=for-the-badge&logo=YouTube&logoColor=blue
|
450
|
+
[🔐security]: SECURITY.md
|
451
|
+
[🔐security-img]: https://img.shields.io/badge/security-policy-brightgreen.svg?style=flat
|
452
|
+
[📄copyright-notice-explainer]: https://opensource.stackexchange.com/questions/5778/why-do-licenses-such-as-the-mit-license-specify-a-single-year
|
453
|
+
[📄license]: LICENSE.txt
|
454
|
+
[📄license-ref]: https://opensource.org/licenses/MIT
|
455
|
+
[📄license-img]: https://img.shields.io/badge/License-MIT-green.svg
|
456
|
+
[📄ilo-declaration]: https://www.ilo.org/declaration/lang--en/index.htm
|
457
|
+
[📄ilo-declaration-img]: https://img.shields.io/badge/ILO_Fundamental_Principles-✓-brightgreen.svg?style=flat
|
458
|
+
[🚎yard-current]: http://rubydoc.info/gems/kettle-soup-cover
|
459
|
+
[🚎yard-head]: https://rubydoc.info/github/kettle-rb/kettle-soup-cover/main
|
data/SECURITY.md
CHANGED
@@ -6,8 +6,16 @@
|
|
6
6
|
|-----------|-----------|
|
7
7
|
| 1.latest | ✅ |
|
8
8
|
|
9
|
-
##
|
9
|
+
## Security contact information
|
10
10
|
|
11
|
-
|
12
|
-
|
13
|
-
|
11
|
+
To report a security vulnerability, please use the
|
12
|
+
[Tidelift security contact](https://tidelift.com/security).
|
13
|
+
Tidelift will coordinate the fix and disclosure.
|
14
|
+
|
15
|
+
## Additional Support
|
16
|
+
|
17
|
+
If you are interested in support for versions older than the latest release,
|
18
|
+
please consider sponsoring the project / maintainer @ https://liberapay.com/pboling/donate,
|
19
|
+
or find other sponsorship links in the [README].
|
20
|
+
|
21
|
+
[README]: README.md
|
@@ -0,0 +1,39 @@
|
|
1
|
+
module Kettle
|
2
|
+
class Change < Module
|
3
|
+
def initialize(constants: nil, path: nil)
|
4
|
+
super()
|
5
|
+
@constants = Array(constants) if constants
|
6
|
+
@path = path if path
|
7
|
+
end
|
8
|
+
|
9
|
+
def included(base)
|
10
|
+
constant_changer = ConstantChange.to_mod(constants: @constants, path: @path)
|
11
|
+
base.send(:extend, constant_changer)
|
12
|
+
end
|
13
|
+
|
14
|
+
module ConstantChange
|
15
|
+
class << self
|
16
|
+
def to_mod(constants: nil, path: nil)
|
17
|
+
Module.new do
|
18
|
+
if constants && path
|
19
|
+
define_method(:reset_const) do |*_args, &block|
|
20
|
+
delete_const do
|
21
|
+
block&.call
|
22
|
+
load(path)
|
23
|
+
end
|
24
|
+
end
|
25
|
+
|
26
|
+
define_method(:delete_const) do |*_args, &block|
|
27
|
+
constants.each do |var|
|
28
|
+
remove_const(var) if defined?(var)
|
29
|
+
end
|
30
|
+
block&.call
|
31
|
+
nil
|
32
|
+
end
|
33
|
+
end
|
34
|
+
end
|
35
|
+
end
|
36
|
+
end
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
@@ -15,38 +15,38 @@
|
|
15
15
|
SimpleCov.configure do
|
16
16
|
track_files("lib/**/*.rb")
|
17
17
|
|
18
|
-
command_name Kettle::Soup::Cover::COMMAND_NAME
|
18
|
+
command_name Kettle::Soup::Cover::Constants::COMMAND_NAME
|
19
19
|
|
20
20
|
enable_coverage :branch
|
21
21
|
primary_coverage :branch
|
22
22
|
|
23
23
|
# Filters (skip these paths for coverage tracking)
|
24
|
-
add_filter Kettle::Soup::Cover::FILTER_DIRS
|
24
|
+
add_filter Kettle::Soup::Cover::Constants::FILTER_DIRS
|
25
25
|
|
26
26
|
# Setup Coverage Dir
|
27
|
-
coverage_dir(Kettle::Soup::Cover::COVERAGE_DIR)
|
27
|
+
coverage_dir(Kettle::Soup::Cover::Constants::COVERAGE_DIR)
|
28
28
|
|
29
29
|
# Formatters
|
30
|
-
if Kettle::Soup::Cover::MULTI_FORMATTERS
|
31
|
-
Kettle::Soup::Cover.load_formatters
|
30
|
+
if Kettle::Soup::Cover::Constants::MULTI_FORMATTERS
|
31
|
+
Kettle::Soup::Cover::Loaders.load_formatters
|
32
32
|
else
|
33
33
|
require "simplecov-html"
|
34
34
|
formatter SimpleCov::Formatter::HTMLFormatter
|
35
35
|
end
|
36
36
|
|
37
37
|
# Use Merging (merges RSpec + Cucumber Test Results)
|
38
|
-
use_merging(Kettle::Soup::Cover::USE_MERGING) unless Kettle::Soup::Cover::USE_MERGING.nil?
|
39
|
-
merge_timeout(Kettle::Soup::Cover::MERGE_TIMEOUT) if Kettle::Soup::Cover::MERGE_TIMEOUT
|
38
|
+
use_merging(Kettle::Soup::Cover::Constants::USE_MERGING) unless Kettle::Soup::Cover::Constants::USE_MERGING.nil?
|
39
|
+
merge_timeout(Kettle::Soup::Cover::Constants::MERGE_TIMEOUT) if Kettle::Soup::Cover::Constants::MERGE_TIMEOUT
|
40
40
|
|
41
41
|
# Fail build when missed coverage targets
|
42
42
|
# NOTE: Checking SpecTracker.instance.full_suite? here would be awesome, but won't work
|
43
43
|
# SpecTracker must wait for instantiation until it has
|
44
44
|
# RSpec's config.world.all_examples,
|
45
45
|
# and that doesn't happen until the before(:suite) hook
|
46
|
-
if Kettle::Soup::Cover::IS_CI || Kettle::Soup::Cover::MIN_COVERAGE_HARD
|
46
|
+
if Kettle::Soup::Cover::Constants::IS_CI || Kettle::Soup::Cover::Constants::MIN_COVERAGE_HARD
|
47
47
|
minimum_coverage(
|
48
|
-
branch: Kettle::Soup::Cover::MIN_COVERAGE_BRANCH,
|
49
|
-
line: Kettle::Soup::Cover::MIN_COVERAGE_LINE,
|
48
|
+
branch: Kettle::Soup::Cover::Constants::MIN_COVERAGE_BRANCH,
|
49
|
+
line: Kettle::Soup::Cover::Constants::MIN_COVERAGE_LINE,
|
50
50
|
)
|
51
51
|
end
|
52
52
|
end
|