Run prettier
This commit is contained in:
parent
8614426b27
commit
f26971f09b
|
@ -17,7 +17,9 @@ import { Await } from './ts';
|
|||
|
||||
export default async function main() {
|
||||
const defaultBump = core.getInput('default_bump') as ReleaseType | 'false';
|
||||
const defaultPreReleaseBump = core.getInput('default_prerelease_bump') as ReleaseType | 'false';
|
||||
const defaultPreReleaseBump = core.getInput('default_prerelease_bump') as
|
||||
| ReleaseType
|
||||
| 'false';
|
||||
const tagPrefix = core.getInput('tag_prefix');
|
||||
const customTag = core.getInput('custom_tag');
|
||||
const releaseBranches = core.getInput('release_branches');
|
||||
|
@ -140,7 +142,7 @@ export default async function main() {
|
|||
// Default bump is set to false and we did not find an automatic bump
|
||||
if (!shouldContinue) {
|
||||
core.debug(
|
||||
'No commit specifies the version bump. Skipping the tag creation.'
|
||||
'No commit specifies the version bump. Skipping the tag creation.'
|
||||
);
|
||||
return;
|
||||
}
|
||||
|
|
|
@ -455,8 +455,8 @@ describe('github-tag-action', () => {
|
|||
setInput('default_prerelease_bump', 'false');
|
||||
const commits: any[] = [];
|
||||
jest
|
||||
.spyOn(utils, 'getCommits')
|
||||
.mockImplementation(async (sha) => commits);
|
||||
.spyOn(utils, 'getCommits')
|
||||
.mockImplementation(async (sha) => commits);
|
||||
|
||||
const validTags = [
|
||||
{
|
||||
|
@ -468,8 +468,8 @@ describe('github-tag-action', () => {
|
|||
},
|
||||
];
|
||||
jest
|
||||
.spyOn(utils, 'getValidTags')
|
||||
.mockImplementation(async () => validTags);
|
||||
.spyOn(utils, 'getValidTags')
|
||||
.mockImplementation(async () => validTags);
|
||||
|
||||
/*
|
||||
* When
|
||||
|
@ -490,8 +490,8 @@ describe('github-tag-action', () => {
|
|||
setInput('default_prerelease_bump', 'prerelease');
|
||||
const commits = [{ message: 'this is my first fix', hash: null }];
|
||||
jest
|
||||
.spyOn(utils, 'getCommits')
|
||||
.mockImplementation(async (sha) => commits);
|
||||
.spyOn(utils, 'getCommits')
|
||||
.mockImplementation(async (sha) => commits);
|
||||
|
||||
const validTags = [
|
||||
{
|
||||
|
@ -500,11 +500,11 @@ describe('github-tag-action', () => {
|
|||
zipball_url: '',
|
||||
tarball_url: 'string',
|
||||
node_id: 'string',
|
||||
}
|
||||
},
|
||||
];
|
||||
jest
|
||||
.spyOn(utils, 'getValidTags')
|
||||
.mockImplementation(async () => validTags);
|
||||
.spyOn(utils, 'getValidTags')
|
||||
.mockImplementation(async () => validTags);
|
||||
|
||||
/*
|
||||
* When
|
||||
|
@ -515,9 +515,9 @@ describe('github-tag-action', () => {
|
|||
* Then
|
||||
*/
|
||||
expect(mockCreateTag).toHaveBeenCalledWith(
|
||||
'v1.2.4-prerelease.0',
|
||||
expect.any(Boolean),
|
||||
expect.any(String)
|
||||
'v1.2.4-prerelease.0',
|
||||
expect.any(Boolean),
|
||||
expect.any(String)
|
||||
);
|
||||
expect(mockSetFailed).not.toBeCalled();
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue