Skip to content
This repository has been archived by the owner on May 21, 2024. It is now read-only.

Fixed coverage and static checks jobs #614

Fixed coverage and static checks jobs

Fixed coverage and static checks jobs #614

Workflow file for this run

name: Aktualizr CI
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
env:
CCACHE_DIR: ${{ github.workspace }}/.ccache
jobs:
coverage:
name: Coverage on Ubuntu Bionic
runs-on: ubuntu-latest
env:
DOCKER_TAG: docker.pkg.github.com/advancedtelematic/aktualizr/aktualizr-ci:bionic-master
DOCKERFILE: docker/Dockerfile.ubuntu.bionic
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
DARGS: >-
-eCCACHE_DIR
-eCODECOV_TOKEN
-eTEST_CMAKE_BUILD_TYPE=Valgrind
-eTEST_WITH_COVERAGE=1
-eTEST_WITH_P11=1
-eTEST_WITH_FAULT_INJECTION=1
-eTEST_TESTSUITE_EXCLUDE=credentials
-eTEST_SOTA_PACKED_CREDENTIALS=dummy-credentials
steps:
- uses: actions/checkout@master
with:
submodules: recursive
- run: git fetch --prune --unshallow
- name: Docker login
if: github.token
run: echo ${{ github.token }} | docker login docker.pkg.github.com -u advancedtelematic --password-stdin
- name: Docker build
run: |
docker pull "$DOCKER_TAG" || true
docker build --cache-from "$DOCKER_TAG" --pull -t "$DOCKER_TAG" -f "$DOCKERFILE" .
- uses: actions/cache@v1.1.0
with:
path: ${{ github.workspace }}/.ccache
key: ubuntu-bionic-${{ github.run_id }}
restore-keys: |
ubuntu-bionic-${{ github.run_id }}
ubuntu-bionic-
- name: Test
run: docker run -v "$PWD:$PWD" -w "$PWD" $DARGS -t "$DOCKER_TAG" ./scripts/test.sh
static-checks:
name: Static checks on Ubuntu Focal
runs-on: ubuntu-latest
env:
DOCKER_TAG: docker.pkg.github.com/advancedtelematic/aktualizr/aktualizr-ci:ubuntu-focal-master
DOCKERFILE: docker/Dockerfile.ubuntu.focal
DARGS: >-
-eCCACHE_DIR
-eTEST_CC=clang
-eTEST_WITH_TESTSUITE=0
-eTEST_WITH_STATICTESTS=1
-eTEST_WITH_DOCS=1
steps:
- uses: actions/checkout@master
with:
submodules: recursive
- run: git fetch --prune --unshallow
- name: Docker login
if: github.token
run: echo ${{ github.token }} | docker login docker.pkg.github.com -u advancedtelematic --password-stdin
- name: Docker build
run: |
docker pull "$DOCKER_TAG" || true
docker build --cache-from "$DOCKER_TAG" --pull -t "$DOCKER_TAG" -f "$DOCKERFILE" .
- uses: actions/cache@v1.1.0
with:
path: ${{ github.workspace }}/.ccache
key: ubuntu-focal-${{ github.run_id }}
restore-keys: |
ubuntu-focal-${{ github.run_id }}
ubuntu-focal-
- name: Test
run: docker run -v "$PWD:$PWD" -w "$PWD" $DARGS -t "$DOCKER_TAG" ./scripts/test.sh