Skip to content

Commit 2bf1c78

Browse files
remove beta ecosystems feature flag for precommit (#14341)
1 parent b829ea0 commit 2bf1c78

File tree

2 files changed

+0
-22
lines changed

2 files changed

+0
-22
lines changed

pre_commit/lib/dependabot/pre_commit/file_fetcher.rb

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -25,13 +25,6 @@ def self.required_files_in?(filenames)
2525

2626
sig { override.returns(T::Array[DependencyFile]) }
2727
def fetch_files
28-
unless allow_beta_ecosystems?
29-
raise Dependabot::DependencyFileNotFound.new(
30-
nil,
31-
"PreCommit support is currently in beta. Set ALLOW_BETA_ECOSYSTEMS=true to enable it."
32-
)
33-
end
34-
3528
fetched_files = []
3629
fetched_files << pre_commit_config
3730

pre_commit/spec/dependabot/pre_commit/file_fetcher_spec.rb

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,6 @@
3333

3434
before do
3535
allow(file_fetcher_instance).to receive(:commit).and_return("sha")
36-
Dependabot::Experiments.register(:enable_beta_ecosystems, true)
3736
end
3837

3938
it_behaves_like "a dependency file fetcher"
@@ -120,19 +119,6 @@
120119
expect(content).to include("v4.4.0")
121120
end
122121

123-
context "when beta ecosystems are disabled" do
124-
before do
125-
Dependabot::Experiments.register(:enable_beta_ecosystems, false)
126-
end
127-
128-
it "raises a DependencyFileNotFound error" do
129-
expect { file_fetcher_instance.files }
130-
.to raise_error(Dependabot::DependencyFileNotFound) do |error|
131-
expect(error.message).to include("beta")
132-
end
133-
end
134-
end
135-
136122
context "when the config file is missing" do
137123
before do
138124
stub_request(:get, url + ".pre-commit-config.yaml?ref=sha")
@@ -149,7 +135,6 @@
149135
context "when exclude_paths is configured" do
150136
before do
151137
allow(Dependabot::Experiments).to receive(:enabled?).and_return(false)
152-
allow(Dependabot::Experiments).to receive(:enabled?).with(:enable_beta_ecosystems).and_return(true)
153138
allow(Dependabot::Experiments).to receive(:enabled?)
154139
.with(:enable_exclude_paths_subdirectory_manifest_files).and_return(true)
155140
file_fetcher_instance.exclude_paths = [".pre-commit-config.yaml"]

0 commit comments

Comments
 (0)