|
28 | 28 | expect(bundled_app("vendor/cache/foo-1.0-#{ref}/.git")).not_to exist |
29 | 29 | expect(bundled_app("vendor/cache/foo-1.0-#{ref}/.bundlecache")).to be_file |
30 | 30 |
|
31 | | - FileUtils.rm_rf lib_path("foo-1.0") |
| 31 | + FileUtils.rm_r lib_path("foo-1.0") |
32 | 32 | expect(the_bundle).to include_gems "foo 1.0" |
33 | 33 | end |
34 | 34 |
|
|
49 | 49 | expect(bundled_app("vendor/cache/foo-1.0-#{ref}")).to exist |
50 | 50 | expect(bundled_app("vendor/cache/foo-1.0-#{ref}/.git")).not_to exist |
51 | 51 |
|
52 | | - FileUtils.rm_rf lib_path("foo-1.0") |
| 52 | + FileUtils.rm_r lib_path("foo-1.0") |
53 | 53 | expect(the_bundle).to include_gems "foo 1.0" |
54 | 54 | end |
55 | 55 |
|
|
66 | 66 | bundle :cache |
67 | 67 |
|
68 | 68 | expect(out).to include "Updating files in vendor/cache" |
69 | | - FileUtils.rm_rf lib_path("foo-1.0") |
| 69 | + FileUtils.rm_r lib_path("foo-1.0") |
70 | 70 | expect(the_bundle).to include_gems "foo 1.0" |
71 | 71 | end |
72 | 72 |
|
|
95 | 95 | expect(bundled_app("vendor/cache/foo-1.0-#{ref}")).to exist |
96 | 96 | expect(bundled_app("vendor/cache/foo-1.0-#{old_ref}")).not_to exist |
97 | 97 |
|
98 | | - FileUtils.rm_rf lib_path("foo-1.0") |
| 98 | + FileUtils.rm_r lib_path("foo-1.0") |
99 | 99 | run "require 'foo'" |
100 | 100 | expect(out).to eq("CACHE") |
101 | 101 | end |
|
124 | 124 | expect(bundled_app("vendor/cache/foo-1.0-#{ref}")).to exist |
125 | 125 | expect(bundled_app("vendor/cache/foo-1.0-#{old_ref}")).not_to exist |
126 | 126 |
|
127 | | - FileUtils.rm_rf lib_path("foo-1.0") |
| 127 | + FileUtils.rm_r lib_path("foo-1.0") |
128 | 128 | run "require 'foo'" |
129 | 129 | expect(out).to eq("CACHE") |
130 | 130 | end |
|
249 | 249 | # Simulate old cache by copying the real cache folder to vendor/cache |
250 | 250 | FileUtils.mkdir_p bundled_app("vendor/cache") |
251 | 251 | FileUtils.cp_r "#{Dir.glob(vendored_gems("cache/bundler/git/foo-1.0-*")).first}/.", cache_dir |
252 | | - FileUtils.rm_rf bundled_app("vendor/bundle") |
| 252 | + FileUtils.rm_r bundled_app("vendor/bundle") |
253 | 253 |
|
254 | 254 | bundle "install --local --verbose" |
255 | 255 | expect(err).to include("Installing from cache in old \"bare repository\" format for compatibility") |
|
281 | 281 | # Simulate old cache by copying the real cache folder to vendor/cache |
282 | 282 | FileUtils.mkdir_p bundled_app("vendor/cache") |
283 | 283 | FileUtils.cp_r "#{Dir.glob(vendored_gems("cache/bundler/git/foo-1.0-*")).first}/.", cache_dir |
284 | | - FileUtils.rm_rf bundled_app("vendor/bundle") |
| 284 | + FileUtils.rm_r bundled_app("vendor/bundle") |
285 | 285 |
|
286 | 286 | bundle "install --verbose" |
287 | 287 | expect(out).to include("Fetching") |
|
423 | 423 | # Simulate an old incorrect situation where vendor/cache would be the install location of git gems |
424 | 424 | FileUtils.mkdir_p bundled_app("vendor/cache") |
425 | 425 | FileUtils.cp_r git_path, bundled_app("vendor/cache/foo-1.0-#{path_revision}") |
426 | | - FileUtils.rm_rf bundled_app("vendor/cache/foo-1.0-#{path_revision}/.git") |
| 426 | + FileUtils.rm_r bundled_app("vendor/cache/foo-1.0-#{path_revision}/.git") |
427 | 427 |
|
428 | 428 | bundle :install, env: { "BUNDLE_DEPLOYMENT" => "true", "BUNDLE_CACHE_ALL" => "true" } |
429 | 429 | end |
|
0 commit comments