mirror of
https://github.com/actions/labeler.git
synced 2025-12-11 12:07:32 +00:00
Further diff reduction
This commit is contained in:
@@ -29,9 +29,6 @@ const configureInput = (
|
|||||||
jest
|
jest
|
||||||
.spyOn(core, 'getInput')
|
.spyOn(core, 'getInput')
|
||||||
.mockImplementation((name: string, ...opts) => mockInput[name]);
|
.mockImplementation((name: string, ...opts) => mockInput[name]);
|
||||||
jest
|
|
||||||
.spyOn(core, 'getBooleanInput')
|
|
||||||
.mockImplementation((name: string, ...opts) => mockInput[name] === true);
|
|
||||||
};
|
};
|
||||||
|
|
||||||
afterAll(() => jest.restoreAllMocks());
|
afterAll(() => jest.restoreAllMocks());
|
||||||
|
|||||||
4
dist/index.js
vendored
4
dist/index.js
vendored
@@ -49,8 +49,8 @@ function run() {
|
|||||||
try {
|
try {
|
||||||
const token = core.getInput('repo-token');
|
const token = core.getInput('repo-token');
|
||||||
const configPath = core.getInput('configuration-path', { required: true });
|
const configPath = core.getInput('configuration-path', { required: true });
|
||||||
const syncLabels = !!core.getBooleanInput('sync-labels', { required: false });
|
const syncLabels = !!core.getInput('sync-labels', { required: false });
|
||||||
const dot = !!core.getBooleanInput('dot', { required: false });
|
const dot = !!core.getInput('dot', { required: false });
|
||||||
const prNumber = getPrNumber();
|
const prNumber = getPrNumber();
|
||||||
if (!prNumber) {
|
if (!prNumber) {
|
||||||
core.info('Could not get pull request number from context, exiting');
|
core.info('Could not get pull request number from context, exiting');
|
||||||
|
|||||||
@@ -15,8 +15,8 @@ export async function run() {
|
|||||||
try {
|
try {
|
||||||
const token = core.getInput('repo-token');
|
const token = core.getInput('repo-token');
|
||||||
const configPath = core.getInput('configuration-path', {required: true});
|
const configPath = core.getInput('configuration-path', {required: true});
|
||||||
const syncLabels = !!core.getBooleanInput('sync-labels', {required: false});
|
const syncLabels = !!core.getInput('sync-labels', {required: false});
|
||||||
const dot = !!core.getBooleanInput('dot', {required: false});
|
const dot = !!core.getInput('dot', {required: false});
|
||||||
|
|
||||||
const prNumber = getPrNumber();
|
const prNumber = getPrNumber();
|
||||||
if (!prNumber) {
|
if (!prNumber) {
|
||||||
|
|||||||
Reference in New Issue
Block a user