-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bundler 2 [pre-release]: Add UpdateChecker #3349
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, I have only one question and it's something we can punt on as we have other things to do to settle the test suite structure, otherwise 🚀
allow(Dependabot::Bundler::NativeHelpers). | ||
to receive(:run_bundler_subprocess). | ||
with({ | ||
bundler_version: "2", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this bundler version set in the stub the only difference between test version? WDYT think about just setting the expectation using something like:
bundler_version: bundler_2_available? ? "2" : "1"
We don't have the fixture swapping wired up based on SUITE_NAME
but when we do, the gemfiles uses should be automagically pulled from the right folder, so it might save some test duplication.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The fixtures are also different between these tests, but I re-checked and it turns out they don't need to be, so let's go with your suggestion 💯
context "bundler v2", :bundler_v2_only do | ||
let(:dependency_files) { project_dependency_files("bundler2/private_git_source") } | ||
|
||
it "updates the dependency" do |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎉
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice!
@@ -1,6 +1,6 @@ | |||
GEM | |||
remote: https://rubygems.org/ | |||
remote: https://wxuokzLuQTRgMGtEYMPJ@repo.fury.io/greysteil/ | |||
remote: https://SECRET_CODES@repo.fury.io/greysteil/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
😬 Thanks for ✂️ this
3bd282f
to
9d2f19a
Compare
private_registry_versions: [:gemfile_name, :dependency_name, :dir, :credentials ], | ||
jfrog_source: [:dir, :gemfile_name, :credentials, :using_bundler2], | ||
git_specs: [:dir, :gemfile_name, :credentials, :using_bundler2], | ||
jfrog_source: %i(dir gemfile_name credentials using_bundler2) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder if this function isn't tested anywhere?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
😬 Possible, we should have cleared out this file by now, right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think it is, I'll add some coverage 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎉
Implements remaining native helpers to get the UpdateChecker to work on v2