豆豆友情提示:这是一个非官方 GitHub 代理镜像,主要用于网络测试或访问加速。请勿在此进行登录、注册或处理任何敏感信息。进行这些操作请务必访问官方网站 github.com。 Raw 内容也通过此代理提供。
Skip to content

Commit af98120

Browse files
committed
Fix tests by stubbing experiment check
1 parent 79914ce commit af98120

File tree

5 files changed

+10
-0
lines changed

5 files changed

+10
-0
lines changed

npm_and_yarn/spec/dependabot/npm_and_yarn/file_updater/npm_lockfile_updater_spec.rb

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,8 @@
7171
.with(:enable_shared_helpers_command_timeout).and_return(true)
7272
allow(Dependabot::Experiments).to receive(:enabled?)
7373
.with(:avoid_duplicate_updates_package_json).and_return(false)
74+
allow(Dependabot::Experiments).to receive(:enabled?)
75+
.with(:enable_dependency_submission_poc).and_return(false)
7476
end
7577

7678
after do

npm_and_yarn/spec/dependabot/npm_and_yarn/file_updater_spec.rb

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,8 @@
6868
.with(:enable_shared_helpers_command_timeout).and_return(true)
6969
allow(Dependabot::Experiments).to receive(:enabled?)
7070
.with(:avoid_duplicate_updates_package_json).and_return(false)
71+
allow(Dependabot::Experiments).to receive(:enabled?)
72+
.with(:enable_dependency_submission_poc).and_return(false)
7173
end
7274

7375
after do

npm_and_yarn/spec/dependabot/npm_and_yarn/update_checker/subdependency_version_resolver_spec.rb

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,8 @@
3838
.with(:enable_corepack_for_npm_and_yarn).and_return(enable_corepack_for_npm_and_yarn)
3939
allow(Dependabot::Experiments).to receive(:enabled?)
4040
.with(:enable_shared_helpers_command_timeout).and_return(true)
41+
allow(Dependabot::Experiments).to receive(:enabled?)
42+
.with(:enable_dependency_submission_poc).and_return(false)
4143
end
4244

4345
after do

npm_and_yarn/spec/dependabot/npm_and_yarn/update_checker/version_resolver_spec.rb

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,8 @@
8080
.with(:enable_corepack_for_npm_and_yarn).and_return(enable_corepack_for_npm_and_yarn)
8181
allow(Dependabot::Experiments).to receive(:enabled?)
8282
.with(:enable_shared_helpers_command_timeout).and_return(true)
83+
allow(Dependabot::Experiments).to receive(:enabled?)
84+
.with(:enable_dependency_submission_poc).and_return(false)
8385
end
8486

8587
after do

npm_and_yarn/spec/dependabot/npm_and_yarn/update_checker_spec.rb

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,8 @@
6868
.with(:enable_corepack_for_npm_and_yarn).and_return(enable_corepack_for_npm_and_yarn)
6969
allow(Dependabot::Experiments).to receive(:enabled?)
7070
.with(:enable_shared_helpers_command_timeout).and_return(true)
71+
allow(Dependabot::Experiments).to receive(:enabled?)
72+
.with(:enable_dependency_submission_poc).and_return(false)
7173
end
7274

7375
after do

0 commit comments

Comments
 (0)