diff options
| author | Ben Fuhrmannek | 2021-08-02 10:42:12 +0200 |
|---|---|---|
| committer | Ben Fuhrmannek | 2021-08-02 10:42:12 +0200 |
| commit | 4cda0120313dfd5d71236f6faf87416e93f5f89c (patch) | |
| tree | 0c2c6d15e8ac5287fb3304f96de719547d9e847a /.github/workflows | |
| parent | 6c132e6a1d8d339a20282afb5a4af52eb6bce9db (diff) | |
| parent | e62f226c3ed885808c832040872fc2d73ca46dac (diff) | |
Merge branch 'master' of https://github.com/jvoisin/snuffleupagus
Diffstat (limited to '.github/workflows')
| -rw-r--r-- | .github/workflows/coverity.yml | 43 | ||||
| -rw-r--r-- | .github/workflows/distributions_php8.yml | 32 |
2 files changed, 75 insertions, 0 deletions
diff --git a/.github/workflows/coverity.yml b/.github/workflows/coverity.yml new file mode 100644 index 0000000..d83aa9f --- /dev/null +++ b/.github/workflows/coverity.yml | |||
| @@ -0,0 +1,43 @@ | |||
| 1 | name: Coverity scan | ||
| 2 | on: | ||
| 3 | schedule: | ||
| 4 | - cron: '0 18 * * 1' # Weekly at 18:00 UTC on Mondays | ||
| 5 | |||
| 6 | jobs: | ||
| 7 | latest: | ||
| 8 | runs-on: ubuntu-latest | ||
| 9 | container: debian:stable | ||
| 10 | steps: | ||
| 11 | - name: Checkout code | ||
| 12 | uses: actions/checkout@v2 | ||
| 13 | - name: Install dependencies | ||
| 14 | run: | | ||
| 15 | apt update | ||
| 16 | DEBIAN_FRONTEND=noninteractive apt install -y --no-install-recommends php-dev curl ca-certificates make gcc | ||
| 17 | - name: Remove php8 tests on php7 | ||
| 18 | run: rm -rf src/tests/*php8*/ | ||
| 19 | - name: Download Coverity Build Tool | ||
| 20 | run: | | ||
| 21 | curl https://scan.coverity.com/download/linux64 --form token=$TOKEN --form project=jvoisin/snuffleupagus -o cov-analysis-linux64.tar.gz | ||
| 22 | mkdir cov-analysis-linux64 | ||
| 23 | tar xzf cov-analysis-linux64.tar.gz --strip-components=1 -C cov-analysis-linux64 | ||
| 24 | env: | ||
| 25 | TOKEN: ${{ secrets.COVERITY_SCAN_TOKEN }} | ||
| 26 | - name: Configure | ||
| 27 | run: cd src; phpize; ./configure --enable-snuffleupagus; cd - | ||
| 28 | - name: Build with cov-build | ||
| 29 | run: ./cov-analysis-linux64/bin/cov-build --dir cov-int make compile_debug | ||
| 30 | - name: Submit the result to Coverity Scan | ||
| 31 | run: | | ||
| 32 | tar czf snuffleupagus.tgz cov-int | ||
| 33 | curl \ | ||
| 34 | --form project=jvoisin/snuffleupagus \ | ||
| 35 | --form token=$TOKEN \ | ||
| 36 | --form file=@snuffleupagus.tgz \ | ||
| 37 | --form version=master \ | ||
| 38 | --form email=julien.voisin+coverity@dustri.org \ | ||
| 39 | --form description=master \ | ||
| 40 | https://scan.coverity.com/builds?project=jvoisin/snuffleupagus | ||
| 41 | env: | ||
| 42 | TOKEN: ${{ secrets.COVERITY_SCAN_TOKEN }} | ||
| 43 | |||
diff --git a/.github/workflows/distributions_php8.yml b/.github/workflows/distributions_php8.yml new file mode 100644 index 0000000..f055499 --- /dev/null +++ b/.github/workflows/distributions_php8.yml | |||
| @@ -0,0 +1,32 @@ | |||
| 1 | name: CI for linux distributions, on php8 | ||
| 2 | on: ['pull_request', 'push'] | ||
| 3 | |||
| 4 | jobs: | ||
| 5 | alpine: | ||
| 6 | runs-on: ubuntu-latest | ||
| 7 | container: alpine:edge | ||
| 8 | steps: | ||
| 9 | - name: Checkout code | ||
| 10 | uses: actions/checkout@v2 | ||
| 11 | - name: Remove php7 tests for php8 | ||
| 12 | run: rm -rf src/tests/*php7*/ | ||
| 13 | - name: Remove tests failing on alpine for wathever reason | ||
| 14 | run: rm -rf src/tests/*session*/ src/tests/broken_configuration/ src/tests/*cookie* src/tests/upload_validation/ | ||
| 15 | - name: Install dependencies | ||
| 16 | run: apk add php8-dev php8-cgi php8-simplexml php8-xml pcre-dev build-base php8-pear php8-openssl | ||
| 17 | - name: Install pecl | ||
| 18 | continue-on-error: true | ||
| 19 | run: pecl install vld-beta | ||
| 20 | - name: Link phpize | ||
| 21 | run: ln -s /usr/bin/phpize8 /usr/bin/phpize | ||
| 22 | - name: Link php-config | ||
| 23 | run: ln -s /usr/bin/php-config8 /usr/bin/php-config | ||
| 24 | - name: Build and run the testsuite | ||
| 25 | continue-on-error: true | ||
| 26 | run: make tests | ||
| 27 | - name: Show logs in case of failure | ||
| 28 | if: ${{ failure() }} | ||
| 29 | continue-on-error: true | ||
| 30 | run: | | ||
| 31 | grep -r . ./src/tests/*/*.out | ||
| 32 | grep -r . ./src/tests/*/*.diff | ||
