Skip to content

Commit 5817594

Browse files
committed
Fix 'bundle exec rake (spec)' so that it works
1 parent 042e8ec commit 5817594

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

Rakefile

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,16 @@
1-
require "rspec/core/rake_task"
21
require "bundler/gem_tasks"
32

43
require_relative "support/current_bundle"
54

6-
RSpec::Core::RakeTask.new(:spec)
5+
begin
6+
require "rspec/core/rake_task"
7+
RSpec::Core::RakeTask.new(:spec)
8+
rescue LoadError
9+
task :spec do
10+
appraisal = SuperDiff::CurrentBundle.instance.latest_appraisal
11+
exec "appraisal install && appraisal #{appraisal.name} rake spec --trace"
12+
end
13+
end
714

815
task :default do
916
if SuperDiff::CurrentBundle.instance.appraisal_in_use?

0 commit comments

Comments
 (0)