Skip to content

Commit 273d9e9

Browse files
committed
! coverage reports now requires token
1 parent 15d5129 commit 273d9e9

File tree

3 files changed

+14
-5
lines changed

3 files changed

+14
-5
lines changed

.github/setup-results.sh

+2-1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ set +x
88
# Passed params
99
DB=$1
1010
PHP_VERSION=$2
11+
CODECOV_TOKEN=$3
1112

1213
# Build a config string for PHPUnit
1314
CONFIG="--verbose --configuration .github/phpunit-${DB}.xml"
@@ -18,5 +19,5 @@ vendor/bin/phpunit ${CONFIG}
1819
# Agents will merge all coverage data...
1920
if [[ "${GITHUB_EVENT_NAME}" == "pull_request" ]]
2021
then
21-
bash <(curl -s https://codecov.io/bash) -s "/tmp" -f '*.xml'
22+
bash <(curl -s https://codecov.io/bash) -s "/tmp" -f '*.xml' -t "${CODECOV_TOKEN}"
2223
fi

.github/setup-selenium.sh

+6-1
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,11 @@
66
set -e
77
set -x
88

9+
# Passed params
10+
DB=$1
11+
PHP_VERSION=$2
12+
CODECOV_TOKEN=$3
13+
914
# Per actions in the tests.yaml file
1015
#
1116
# Current Versions for Ref
@@ -42,6 +47,6 @@ else
4247
# Agents will merge all coverage data...
4348
if [[ "${GITHUB_EVENT_NAME}" == "pull_request" ]]
4449
then
45-
bash <(curl -s https://codecov.io/bash) -s "/tmp" -f '*.clover'
50+
bash <(curl -s https://codecov.io/bash) -s "/tmp" -f '*.xml' -t "${CODECOV_TOKEN}"
4651
fi
4752
fi

.github/workflows/tests.yaml

+6-3
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,8 @@ jobs:
9696
env:
9797
DB: ${{ matrix.db }}
9898
PHP_VERSION: ${{ matrix.php }}
99-
run: .github/setup-selenium.sh $DB $PHP_VERSION
99+
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
100+
run: .github/setup-selenium.sh $DB $PHP_VERSION $CODECOV_TOKEN
100101
working-directory: ./elkarte
101102
continue-on-error: true
102103

@@ -244,7 +245,8 @@ jobs:
244245
env:
245246
DB: ${{steps.database-type.outputs.db}}
246247
PHP_VERSION: ${{ matrix.php }}
247-
run: .github/setup-results.sh $DB $PHP_VERSION
248+
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
249+
run: .github/setup-results.sh $DB $PHP_VERSION $CODECOV_TOKEN
248250
working-directory: ./elkarte
249251
# END MySQL and MariaDB Job
250252

@@ -323,6 +325,7 @@ jobs:
323325
env:
324326
DB: ${{steps.database-type.outputs.db}}
325327
PHP_VERSION: ${{ matrix.php }}
326-
run: .github/setup-results.sh $DB $PHP_VERSION
328+
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
329+
run: .github/setup-results.sh $DB $PHP_VERSION $CODECOV_TOKEN
327330
working-directory: ./elkarte
328331
# END Postgres Job

0 commit comments

Comments
 (0)