File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 99RSpec . describe "Rails integration" , :integration do
1010 GEM_ROOT = File . expand_path ( "../.." , __dir__ )
1111
12- def run_cmd! ( cmd , chdir :)
13- output , status = Bundler . with_unbundled_env do
12+ def run_cmd! ( cmd , chdir :, unbundled : true )
13+ output , status = if unbundled
14+ Bundler . with_unbundled_env { Open3 . capture2e ( cmd , chdir : chdir ) }
15+ else
1416 Open3 . capture2e ( cmd , chdir : chdir )
1517 end
1618 unless status . success?
@@ -23,8 +25,8 @@ def run_cmd!(cmd, chdir:)
2325 @tmpdir = Dir . mktmpdir ( "fixturebot_integration" )
2426 @app_dir = File . join ( @tmpdir , "dummy_app" )
2527
26- # Create a new minimal Rails app
27- run_cmd! ( "rails new dummy_app --minimal --skip-git --skip-docker --skip-bundle" , chdir : @tmpdir )
28+ # Create a new minimal Rails app (runs within parent bundle to find rails CLI)
29+ run_cmd! ( "rails new dummy_app --minimal --skip-git --skip-docker --skip-bundle" , chdir : @tmpdir , unbundled : false )
2830
2931 # Add fixturebot to Gemfile
3032 gemfile = File . join ( @app_dir , "Gemfile" )
You can’t perform that action at this time.
0 commit comments