diff --git a/.github/workflows/ci_reuse_go_cas.yml b/.github/workflows/ci_reuse_go_cas.yml index 2e65a40..00d73a7 100644 --- a/.github/workflows/ci_reuse_go_cas.yml +++ b/.github/workflows/ci_reuse_go_cas.yml @@ -11,6 +11,9 @@ on: short_test: required: false type: string + ignore_build: + required: false + type: string go_race: required: false type: string @@ -67,6 +70,7 @@ jobs: token: ${{ secrets.reporeading_token }} codecov-token: ${{ secrets.codecov_token }} short-test: ${{ secrets.short_test }} + ignore-build: ${{ secrets.ignore_build }} run-mod-tidy: false env: CHARGEBEE_PUBLISHABLE_KEY: ${{ secrets.chargebee_token }} diff --git a/dist/index.js b/dist/index.js index f7ed2be..7307574 100644 --- a/dist/index.js +++ b/dist/index.js @@ -17335,7 +17335,7 @@ async function run() { const ignore = getInputAsArray('ignore') const organization = getInputAsArray('organization') const token = core.getInput('token') - const codecovToken = core.getInput('codecov-token') + const codecovToken = core.getInput('codecov-token') === '' const codecovGoRace = core.getInput ('codecov-go-race') === 'true' const publishAsset = core.getInput('publish-asset') const publishToken = core.getInput('publish-token') @@ -17417,7 +17417,7 @@ async function run() { } // run Codecov / test - if (codecovToken) { + if (codecovToken !== "") { core.startGroup('Codecov') await execute('go install github.com/heeus/gocov@latest') let tststr='' @@ -17433,16 +17433,15 @@ async function run() { else tststr ='go test ./... -coverprofile=coverage.txt -covermode=atomic -coverpkg=./...' - if (shorttest){ + if (shorttest == "true"){ tststr=tststr + ' -short' - tststr ='go test ./... -coverprofile=coverage.txt -covermode=atomic -coverpkg=./...' } await execute(tststr) core.endGroup() await execute(`bash -c "bash <(curl -Os https://uploader.codecov.io/latest/linux/codecov) -t ${codecovToken}"`) } else { let tststr='go test ./...' - if (shorttest){ + if (shorttest == "true"){ tststr=tststr + ' -short' } await execute(tststr) diff --git a/index.js b/index.js index 386c640..9ebac9f 100644 --- a/index.js +++ b/index.js @@ -22,7 +22,7 @@ async function run() { const ignore = getInputAsArray('ignore') const organization = getInputAsArray('organization') const token = core.getInput('token') - const codecovToken = core.getInput('codecov-token') + const codecovToken = core.getInput('codecov-token') === '' const codecovGoRace = core.getInput ('codecov-go-race') === 'true' const publishAsset = core.getInput('publish-asset') const publishToken = core.getInput('publish-token') @@ -104,7 +104,7 @@ async function run() { } // run Codecov / test - if (codecovToken) { + if (codecovToken !== "") { core.startGroup('Codecov') await execute('go install github.com/heeus/gocov@latest') let tststr='' @@ -114,22 +114,20 @@ async function run() { else tststr='gocov -t="-covermode=atomic" -v' */ - if (codecovGoRace) tststr = 'go test ./... -race -coverprofile=coverage.txt -covermode=atomic -coverpkg=./...' else tststr ='go test ./... -coverprofile=coverage.txt -covermode=atomic -coverpkg=./...' - if (shorttest){ + if (shorttest == "true"){ tststr=tststr + ' -short' - tststr ='go test ./... -coverprofile=coverage.txt -covermode=atomic -coverpkg=./...' } await execute(tststr) core.endGroup() await execute(`bash -c "bash <(curl -Os https://uploader.codecov.io/latest/linux/codecov) -t ${codecovToken}"`) } else { let tststr='go test ./...' - if (shorttest){ + if (shorttest == "true"){ tststr=tststr + ' -short' } await execute(tststr)