Class: Loupe::RakeTask
- Inherits:
-
Rake::TaskLib
- Object
- Rake::TaskLib
- Loupe::RakeTask
- Defined in:
- lib/loupe/rake_task.rb
Overview
Loupe’s test rake task
Define a rake task so that we can hook into ‘rake test` an run the suite using Loupe. To hook it up, add this to the Rakefile
require “loupe/rake_task”
Loupe::RakeTask.new do |options|
<< "--plain"
<< "--ractor"
end
Then run with ‘bundle exec rake test`
Instance Attribute Summary collapse
-
#description ⇒ Object
Returns the value of attribute description.
-
#libs ⇒ Object
Returns the value of attribute libs.
-
#name ⇒ Object
Returns the value of attribute name.
Instance Method Summary collapse
- #initialize {|@options| ... } ⇒ Loupe::RakeTask constructor
Constructor Details
#initialize {|@options| ... } ⇒ Loupe::RakeTask
26 27 28 29 30 31 32 33 34 35 36 |
# File 'lib/loupe/rake_task.rb', line 26 def initialize super @name = "test" @description = "Run tests using Loupe" @libs = %w[lib test] @options = [] ARGV.shift if ARGV.first == "test" yield(@options) define end |
Instance Attribute Details
#description ⇒ Object
Returns the value of attribute description.
23 24 25 |
# File 'lib/loupe/rake_task.rb', line 23 def description @description end |
#libs ⇒ Object
Returns the value of attribute libs.
23 24 25 |
# File 'lib/loupe/rake_task.rb', line 23 def libs @libs end |
#name ⇒ Object
Returns the value of attribute name.
23 24 25 |
# File 'lib/loupe/rake_task.rb', line 23 def name @name end |