|
73 | 73 | describe "fetching and parsing the bun.lock" do
|
74 | 74 | before do
|
75 | 75 | allow(Dependabot::Experiments).to receive(:enabled?)
|
76 |
| - allow(Dependabot::Experiments).to receive(:enabled?) |
77 |
| - .with(:enable_bun_ecosystem).and_return(enable_beta_ecosystems) |
78 |
| - allow(Dependabot::Experiments).to receive(:enabled?) |
79 |
| - .with(:enable_beta_ecosystems).and_return(enable_beta_ecosystems) |
80 | 76 | end
|
81 | 77 |
|
82 |
| - context "when the experiment :enable_beta_ecosystems is inactive" do |
83 |
| - let(:enable_beta_ecosystems) { false } |
84 |
| - |
85 |
| - it "does not fetch or parse the the bun.lock" do |
86 |
| - expect(file_fetcher_instance.files.map(&:name)) |
87 |
| - .to match_array(%w(package.json)) |
88 |
| - expect(file_fetcher_instance.ecosystem_versions) |
89 |
| - .to match({ package_managers: { "unknown" => an_instance_of(Integer) } }) |
90 |
| - end |
91 |
| - end |
92 |
| - |
93 |
| - context "when the experiment :enable_beta_ecosystems is active" do |
94 |
| - let(:enable_beta_ecosystems) { true } |
95 |
| - |
96 |
| - it "fetches and parses the bun.lock" do |
97 |
| - expect(file_fetcher_instance.files.map(&:name)) |
98 |
| - .to match_array(%w(package.json bun.lock)) |
99 |
| - expect(file_fetcher_instance.ecosystem_versions) |
100 |
| - .to match({ package_managers: { "bun" => an_instance_of(Integer) } }) |
101 |
| - end |
| 78 | + it "fetches and parses the bun.lock" do |
| 79 | + expect(file_fetcher_instance.files.map(&:name)) |
| 80 | + .to match_array(%w(package.json bun.lock)) |
| 81 | + expect(file_fetcher_instance.ecosystem_versions) |
| 82 | + .to match({ package_managers: { "bun" => an_instance_of(Integer) } }) |
102 | 83 | end
|
103 | 84 | end
|
104 | 85 | end
|
|
0 commit comments