-
Notifications
You must be signed in to change notification settings - Fork 39
fix: semver like titles #125
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -263,3 +263,29 @@ tap.test('should call external api for github-action-merge-dependabot major rele | |
| t.ok(stubs.logStub.logWarning.calledOnce) | ||
| t.ok(stubs.fetchStub.calledOnce) | ||
| }) | ||
|
|
||
| tap.test('should check submodules semver when target is set', async t => { | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. this is not what submodules look like. submodules have a commit sha in the pr title (iirc) #95 There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @Eomm lmk if the comment is clear. It's about the title of the PR you have in this test not matching what happens when a version of a submodule tries to be bumped. You only get a SHA in that case There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yeah, I'm on it. Let me push the wip code I'm trying to ignore the case:
this check is a bit tricky due the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. we don't have to support everything, it would be a good step if we didn't break anything of the existing and we document the behavior for edge cases so we know what we can work on next There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I have implemented the most simple check, using this PR as reference: |
||
| const PR_NUMBER = Math.random() | ||
| const { action, stubs } = buildStubbedAction({ | ||
| payload: { | ||
| pull_request: { | ||
| number: PR_NUMBER, | ||
| title: 'Bump dotbot from `aa93350` to `ac5793c`', | ||
| user: { login: BOT_NAME }, | ||
| head: { ref: 'dependabot/submodules/dotbot-ac5793c' }, | ||
| } | ||
| }, | ||
| inputs: { | ||
| PR_NUMBER, | ||
| TARGET: 'minor', | ||
| EXCLUDE_PKGS: [], | ||
| API_URL: 'custom one', | ||
| DEFAULT_API_URL, | ||
| } | ||
| }) | ||
|
|
||
| await action() | ||
|
|
||
| t.ok(stubs.logStub.logWarning.calledOnceWith('Target specified does not match to PR, skipping.')) | ||
| t.ok(stubs.fetchStub.notCalled) | ||
| }) | ||
Uh oh!
There was an error while loading. Please reload this page.