Skip to content
This repository was archived by the owner on Oct 6, 2025. It is now read-only.

testing action doxygen #36

testing action doxygen

testing action doxygen #36

Workflow file for this run

name: Google Testing
on:
push:
branches:
- dev
jobs:
run-tests:
runs-on: ubuntu-latest
steps:
- name: Checkout Code
uses: actions/checkout@v3
- name: Install Dependencies
run: |
sudo apt-get update
sudo apt-get install -y doxygen graphviz lcov g++ cmake qtbase5-dev qtbase5-private-dev libqt5widgets5 libqt5gui5 xvfb
git clone -b 5.15 https://code.qt.io/qt/qtmqtt.git ./qtmqtt
cd qtmqtt
qmake
make
sudo make install
- name: Build and Run GTests
env:
user: "${{ secrets.USER }}"
password: "${{ secrets.MQTT_PASSWORD }}"
run: |
cd digital_cluster
rm -rf build
mkdir build
cd build
cmake -DCMAKE_BUILD_TYPE=Debug -DBUILD_TESTS=ON ..
make
xvfb-run -a ./digital_cluster_test
lcov --capture --directory . --output-file coverage.info --ignore-errors mismatch,unused
lcov --remove coverage.info '*/build/*' '*/test/*' '/usr/*' --output-file coverage.info
genhtml coverage.info --output-directory coverage_report
# Gerar documentação
- name: Generate Documentation
run: cd doxyfiles && doxygen Doxyfile
- name: Upload Coverage Report
uses: actions/upload-artifact@v4
with:
name: coverage-report
path: digital_cluster/build/coverage_report/
# retention-days: 7
- name: Upload Doxygen Documentation
uses: actions/upload-artifact@v4
with:
name: doxygen-docs
path: doxyfiles/docs # Adjust to your Doxygen output directory
# retention-days: 7
- name: Move coverage report into docs
run: |
mkdir -p doxyfiles/docs/coverage
cp -r digital_cluster/build/coverage_report/* doxyfiles/docs/coverage/
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.PAT_TOKEN }}
publish_dir: doxyfiles/docs
# destination_dir: ./
force_orphan: true
# user_name: github-actions
# user_email: github-actions@github.com
# keep_files: true
# exclude_assets: '**/*.md'