From a27c38e00475014c535fdc158ce7484b76e30996 Mon Sep 17 00:00:00 2001 From: ivvist Date: Sun, 17 Nov 2024 18:59:17 +0100 Subject: [PATCH] fix short test --- index.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/index.js b/index.js index 65a467e..104cd72 100644 --- a/index.js +++ b/index.js @@ -31,7 +31,7 @@ async function run() { const runModTidy = core.getInput('run-mod-tidy') === 'false' const mainBranch = core.getInput('main-branch') const ignoreCopyright = core.getInput('ignore-copyright') === 'true' - const ignoreRunBuild = core.getInput('ignore-build') === 'true' + const ignoreRunBuild = core.getInput('ignore-build') const testfolder = core.getInput('test-folder') const shorttest = core.getInput ('short-test') === 'true' @@ -95,11 +95,11 @@ async function run() { await execute('cd ' + testfolder) } - if (!ignoreRunBuild) { + if (ignoreRunBuild !== "true") { await execute('go build ./...') } - if (runModTidy == "true") { + if (runModTidy === "true") { await execute('go mod tidy') } @@ -120,7 +120,7 @@ async function run() { else tststr ='go test ./... -coverprofile=coverage.txt -covermode=atomic -coverpkg=./...' - if (shorttest == "true"){ + if (shorttest === "true"){ tststr=tststr + ' -short' } await execute(tststr) @@ -128,7 +128,7 @@ async function run() { await execute(`bash -c "bash <(curl -Os https://uploader.codecov.io/latest/linux/codecov) -t ${codecovToken}"`) } else { let tststr='go test ./...' - if (shorttest == "true"){ + if (shorttest === "true"){ tststr=tststr + ' -short' } await execute(tststr)