You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
| Works with JRuby |![JRuby 9.1 Compat][💎jruby-9.1i]![JRuby 9.2 Compat][💎jruby-9.2i]![JRuby 9.3 Compat][💎jruby-9.3i] <br/> [![JRuby 9.4 Compat][💎jruby-9.4i]][🚎10-j-wf][![JRuby 10.0 Compat][💎jruby-c-i]][🚎11-c-wf][![JRuby HEAD Compat][💎jruby-headi]][🚎3-hd-wf]|
44
-
| Works with Truffle Ruby |![Truffle Ruby 22.3 Compat][💎truby-22.3i]![Truffle Ruby 23.0 Compat][💎truby-23.0i] <br/> [![Truffle Ruby 23.1 Compat][💎truby-23.1i]][🚎9-t-wf][![Truffle Ruby 24.1 Compat][💎truby-c-i]][🚎11-c-wf]|
45
-
| 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]|
46
-
| Works with MRI Ruby 2 | <br/> [![Ruby 2.3 Compat][💎ruby-2.3i]][🚎1-an-wf][![Ruby 2.4 Compat][💎ruby-2.4i]][🚎1-an-wf][![Ruby 2.5 Compat][💎ruby-2.5i]][🚎1-an-wf][![Ruby 2.6 Compat][💎ruby-2.6i]][🚎7-us-wf][![Ruby 2.7 Compat][💎ruby-2.7i]][🚎7-us-wf]|
47
-
| 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]|
48
-
| Documentation |[![Current release on RubyDoc.info][📜docs-cr-rd-img]][🚎yard-current][![YARD on Galtzo.com][📜docs-head-rd-img]][🚎yard-head][![Maintainer Blog][🚂maint-blog-img]][🚂maint-blog][![Wiki][📜wiki-img]][📜wiki]|
| Support |[![Live Chat on Discord][✉️discord-invite-img]][✉️discord-invite][![Get help from me on Upwork][👨🏼🏫expsup-upwork-img]][👨🏼🏫expsup-upwork][![Get help from me on Codementor][👨🏼🏫expsup-codementor-img]][👨🏼🏫expsup-codementor]|
52
-
| Maintainer 🎖️ |[![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 Maintainer][🚂maint-contact-img]][🚂maint-contact][![My technical writing][💖💁🏼♂️devto-img]][💖💁🏼♂️devto]|
53
-
|`...` 💖 |[![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]|
41
+
| Tokens to Remember |[![Gem name][⛳️name-img]][⛳️gem-name][![Gem namespace][⛳️namespace-img]][⛳️gem-namespace]|
| Works with JRuby |![JRuby 9.1 Compat][💎jruby-9.1i]![JRuby 9.2 Compat][💎jruby-9.2i]![JRuby 9.3 Compat][💎jruby-9.3i] <br/> [![JRuby 9.4 Compat][💎jruby-9.4i]][🚎10-j-wf][![JRuby 10.0 Compat][💎jruby-c-i]][🚎11-c-wf][![JRuby HEAD Compat][💎jruby-headi]][🚎3-hd-wf]|
44
+
| Works with Truffle Ruby |![Truffle Ruby 22.3 Compat][💎truby-22.3i]![Truffle Ruby 23.0 Compat][💎truby-23.0i] <br/> [![Truffle Ruby 23.1 Compat][💎truby-23.1i]][🚎9-t-wf][![Truffle Ruby 24.1 Compat][💎truby-c-i]][🚎11-c-wf]|
45
+
| 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]|
46
+
| Works with MRI Ruby 2 |[![Ruby 2.3 Compat][💎ruby-2.3i]][🚎1-an-wf][![Ruby 2.4 Compat][💎ruby-2.4i]][🚎1-an-wf][![Ruby 2.5 Compat][💎ruby-2.5i]][🚎1-an-wf][![Ruby 2.6 Compat][💎ruby-2.6i]][🚎7-us-wf][![Ruby 2.7 Compat][💎ruby-2.7i]][🚎7-us-wf]|
47
+
| 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]|
48
+
| Documentation |[![Current release on RubyDoc.info][📜docs-cr-rd-img]][🚎yard-current][![YARD on Galtzo.com][📜docs-head-rd-img]][🚎yard-head][![Maintainer Blog][🚂maint-blog-img]][🚂maint-blog][![Wiki][📜wiki-img]][📜wiki]|
| Support |[![Live Chat on Discord][✉️discord-invite-img]][✉️discord-invite][![Get help from me on Upwork][👨🏼🏫expsup-upwork-img]][👨🏼🏫expsup-upwork][![Get help from me on Codementor][👨🏼🏫expsup-codementor-img]][👨🏼🏫expsup-codementor]|
52
+
| Maintainer 🎖️ |[![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 Maintainer][🚂maint-contact-img]][🚂maint-contact][![My technical writing][💖💁🏼♂️devto-img]][💖💁🏼♂️devto]|
53
+
|`...` 💖 |[![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]|
54
54
55
55
### Compatibility
56
56
@@ -251,6 +251,26 @@ end
251
251
252
252
## 🔧 Basic Usage
253
253
254
+
### Shared Context "with rake"
255
+
256
+
Make sure to require "rake" before you require "kettle/test" (or "kettle/dev" since it will require this library).
257
+
258
+
If you do the shared context will be available to use in your specs automatically.
259
+
260
+
```ruby
261
+
include_context "with rake", "demo"do
262
+
let(:tmp_rakelib) do
263
+
Dir.mktmpdir("with_rake_spec_")
264
+
end
265
+
let(:task_dir) { tmp_rakelib }
266
+
let(:rakelib) { tmp_rakelib }
267
+
# Provide args for the rake task invocation
268
+
let(:task_args) { ["Bob"] }
269
+
end
270
+
```
271
+
272
+
See the spec for a more complete example: See for more details: [with_rake_spec.rb](spec/kettle/text/support/shared_contexts/with_rake_spec.rb)
273
+
254
274
### RSpec Time Machine Tags :freeze and :travel
255
275
256
276
Timecop.travel/freeze any RSpec (describe|context|example) with
0 commit comments