2019-11-20 20:34:55 -08:00
|
|
|
name: Unit Test CI
|
2019-11-20 16:22:16 -08:00
|
|
|
|
2019-11-20 20:34:55 -08:00
|
|
|
on: [push,pull_request]
|
2019-11-20 16:22:16 -08:00
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
2020-09-08 10:50:30 -07:00
|
|
|
runs-on: ubuntu-20.04
|
2019-11-20 16:22:16 -08:00
|
|
|
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v1
|
2019-11-20 16:28:14 -08:00
|
|
|
with:
|
|
|
|
submodules: recursive
|
2019-11-20 16:22:16 -08:00
|
|
|
|
2020-06-18 15:31:54 -07:00
|
|
|
- name: Generate Configs
|
|
|
|
working-directory: ./firmware/
|
2020-07-14 07:28:26 -07:00
|
|
|
run: bash gen_config_default.sh
|
2020-06-18 15:31:54 -07:00
|
|
|
|
|
|
|
- name: Generate Live Documentation
|
|
|
|
working-directory: ./firmware/
|
2020-07-14 07:28:26 -07:00
|
|
|
run: bash gen_live_documentation.sh
|
2020-06-18 15:31:54 -07:00
|
|
|
|
2020-09-08 10:12:07 -07:00
|
|
|
- name: Install gcc8
|
|
|
|
run: sudo apt-get install -y gcc-8
|
|
|
|
|
|
|
|
- name: Print GCC version
|
2020-09-08 09:45:33 -07:00
|
|
|
working-directory: .
|
2020-09-08 10:27:07 -07:00
|
|
|
run: gcc -v
|
2020-09-08 09:45:33 -07:00
|
|
|
|
2019-11-20 16:36:14 -08:00
|
|
|
- name: Build Tests
|
2019-11-20 16:28:14 -08:00
|
|
|
working-directory: ./unit_tests/
|
2019-11-20 16:36:28 -08:00
|
|
|
run: make -j4
|
2019-11-20 16:36:14 -08:00
|
|
|
|
|
|
|
- name: Run Tests
|
|
|
|
run: ./unit_tests/build/rusefi_test
|
2020-06-16 14:39:50 -07:00
|
|
|
|
|
|
|
- name: Install Coverage Tools
|
|
|
|
run: sudo apt-get install ncftp lcov
|
|
|
|
|
|
|
|
- name: Generate Code Coverage
|
|
|
|
working-directory: ./unit_tests/
|
|
|
|
run: ./ci_gcov.sh ${{ secrets.RUSEFI_DOXYGEN_FTP_USER }} ${{ secrets.RUSEFI_DOXYGEN_FTP_PASS }} ${{ secrets.RUSEFI_FTP_SERVER }}
|