Skip to content

GitHub action replaced alpine VM #5

GitHub action replaced alpine VM

GitHub action replaced alpine VM #5

Workflow file for this run

name: tddc-301 exercises
on: [push]
jobs:
build:
runs-on: ubuntu-latest
environment: build
container:
image: feabhas/ceedling
options: -u 1001
steps:
- name: checkout
uses: actions/checkout@v4
with:
sparse-checkout: solutions
fetch-depth: 1
- name : build and test Exercise 1
run: |
cd solutions/exercise-1
ceedling test:all
mkdir -p build/test-reports
cp build/artifacts/test/*.xml build/test-reports/
- name : build and test Exercise 2
run: |
cd solutions/exercise-2
ceedling test:all
mkdir -p build/test-reports
cp build/artifacts/test/*.xml build/test-reports/
- name : build and test Exercise 4
run: |
cd solutions/exercise-4
ceedling test:all
mkdir -p build/test-reports
cp build/artifacts/test/*.xml build/test-reports/
- name: Coverage for Exercise 4
run: |
cd solutions/exercise-4
ceedling gcov:all
ceedling utils:gcov
mkdir -p build/test-reports
cp build/artifacts/gcov/*.xml build/test-reports/
check:
runs-on: ubuntu-latest
environment: build
container:
image: feabhas/ubuntu-projects
options: -u 1001
steps:
- name: checkout
uses: actions/checkout@v4
with:
sparse-checkout: solutions
fetch-depth: 1
- name: CC Check
run: |
pip3 install lizard
cd solutions/exercise-1/src
lizard
cd ../../exercise-2/src
lizard
cd ../../exercise-4/src
lizard
lint:
runs-on: ubuntu-latest
environment: build
container:
image: feabhas/oclint-0.13
options: -u 1001
steps:
- name: checkout
uses: actions/checkout@v4
with:
sparse-checkout: solutions
fetch-depth: 1
- name: CC Check
run: |
cd solutions/exercise-1
oclint src/*.c -- -c -I vendor/ceedling/vendor/unity/src/
cd ../exercise-2
oclint src/*.c -- -c -I vendor/ceedling/vendor/unity/src/
cd ../exercise-4
oclint src/*.c -- -c -I vendor/ceedling/vendor/unity/src/