Skip to content

Commit

Permalink
Add rake task for rspec
Browse files Browse the repository at this point in the history
  • Loading branch information
TonyCTHsu committed May 10, 2024
1 parent 509772a commit 857f7ce
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ Dir.glob(File.join(__dir__ || Dir.pwd, "tasks", "*.rake")) { |f| import f }
desc "Run checks"
task :check

task default: [:test, :check]
task default: [:check, :spec, :test]
10 changes: 10 additions & 0 deletions tasks/rspec.rake
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# frozen_string_literal: true

# @type self: Rake::DSL

require "rspec/core/rake_task"

RSpec::Core::RakeTask.new(:spec) do |t, args|
t.pattern = "spec/**/*_spec.rb"
t.rspec_opts = args.to_a.join(" ")
end

0 comments on commit 857f7ce

Please sign in to comment.