Skip to content

Commit 3390b6a

Browse files
committed
Added simple failing example
1 parent c5c0bb5 commit 3390b6a

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

spec/bundled_gems_spec.rb

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -361,4 +361,17 @@ def my
361361

362362
expect(err).to be_empty
363363
end
364+
365+
describe ".force_activate" do
366+
context "when gem activation fails" do
367+
before do
368+
allow_any_instance_of(Bundler::Runtime).to receive(:setup).and_raise(Bundler::GemNotFound)
369+
end
370+
371+
it "warns about installation requirement" do
372+
expect_any_instance_of(Object).to receive(:warn)
373+
Gem::BUNDLED_GEMS.force_activate("csv")
374+
end
375+
end
376+
end
364377
end

0 commit comments

Comments
 (0)