From 80af19fe096b8177cee066cee217bc5f502fa6f9 Mon Sep 17 00:00:00 2001 From: Spiros Maggioros Date: Thu, 1 Aug 2024 23:00:39 +0300 Subject: [PATCH] Changed codecov to macos latest --- .github/workflows/coverage.yml | 4 +- .github/workflows/macos_test_cases.yml | 49 +++++++++++++---------- .github/workflows/ubuntu_test_cases.yml | 53 +++++++++++-------------- 3 files changed, 53 insertions(+), 53 deletions(-) diff --git a/.github/workflows/coverage.yml b/.github/workflows/coverage.yml index 67912549..539665dd 100644 --- a/.github/workflows/coverage.yml +++ b/.github/workflows/coverage.yml @@ -4,7 +4,7 @@ env: BUILD_TYPE: Debug jobs: coverage: - runs-on: ubuntu-latest + runs-on: macos-latest steps: - uses: actions/checkout@v2 @@ -34,4 +34,4 @@ jobs: - name: Coverage working-directory: ${{runner.workspace}}/build shell: bash - run: make coverage \ No newline at end of file + run: make coverage diff --git a/.github/workflows/macos_test_cases.yml b/.github/workflows/macos_test_cases.yml index 598dbf82..710b08e2 100644 --- a/.github/workflows/macos_test_cases.yml +++ b/.github/workflows/macos_test_cases.yml @@ -4,9 +4,9 @@ name: macos-test-cases on: push: - branches: [ "main" ] + branches: ["main"] pull_request: - branches: [ "main" ] + branches: ["main"] env: # Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.) @@ -17,23 +17,30 @@ jobs: # The CMake configure and build commands are platform agnostic and should work equally well on Windows or Mac. # You can convert this to a matrix build if you need cross-platform coverage. # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix - runs-on: macos-latest - + runs-on: macos-latest + steps: - - uses: actions/checkout@v3 - - name: Download requirements - run: sudo pip3 install xcrun --break-system-packages && sudo pip3 install gcovr --break-system-packages && brew install lcov libxrandr libxcursor libuv openal-soft flac libvorbis mesa freeglut - - name: Install dependencies - run: pip install -r requirements.txt - - name: Configure CMake - # Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make. - # See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type - run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DENABLE_COVERAGE=true - - name: Build - # Build your program with the given configuration - run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} - - name: Test - working-directory: ${{github.workspace}}/build - # Execute tests defined by the CMake configuration. - # See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail - run: ctest --output-on-failure \ No newline at end of file + - uses: actions/checkout@v3 + - name: Download requirements + run: sudo pip3 install xcrun --break-system-packages && sudo pip3 install gcovr --break-system-packages && brew install lcov libxrandr libxcursor libuv openal-soft flac libvorbis mesa freeglut + - name: Install dependencies + run: pip install -r requirements.txt + - name: Configure CMake + # Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make. + # See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type + run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DENABLE_COVERAGE=true + - name: Build + # Build your program with the given configuration + run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} + - name: Test + working-directory: ${{github.workspace}}/build + # Execute tests defined by the CMake configuration. + # See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail + run: ctest --output-on-failure + - name: Upload coverage reports to Codecov + uses: codecov/codecov-action@v4.0.1 + with: + token: ${{ secrets.CODECOV_TOKEN }} + slug: CSRT-NTUA/AlgoPlus + - name: Upload to codecov + run: bash <(curl -s https://codecov.io/bash) diff --git a/.github/workflows/ubuntu_test_cases.yml b/.github/workflows/ubuntu_test_cases.yml index 360262ba..499596ba 100644 --- a/.github/workflows/ubuntu_test_cases.yml +++ b/.github/workflows/ubuntu_test_cases.yml @@ -4,9 +4,9 @@ name: ubuntu-test-cases on: push: - branches: [ "main" ] + branches: ["main"] pull_request: - branches: [ "main" ] + branches: ["main"] env: # Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.) @@ -18,35 +18,28 @@ jobs: # You can convert this to a matrix build if you need cross-platform coverage. # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix runs-on: ubuntu-latest - + steps: - - uses: actions/checkout@v3 - - name: Download requirements - run: sudo pip3 install xcrun && sudo pip3 install gcovr && sudo apt-get update && sudo apt-get install lcov libxrandr-dev libxcursor-dev libudev-dev libopenal-dev libflac-dev libvorbis-dev libgl1-mesa-dev libegl1-mesa-dev freeglut3-dev # OpenGL dependencies only needed for SFML - - name: Install dependencies - run: pip install -r requirements.txt - - name: Configure CMake - # Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make. - # See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type - run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DENABLE_COVERAGE=true - - name: Build - # Build your program with the given configuration - run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} - - name: Test - working-directory: ${{github.workspace}}/build - # Execute tests defined by the CMake configuration. - # See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail - run: ctest --output-on-failure - - name: clang-tidy - run: bash clang_tidy.sh + - uses: actions/checkout@v3 + - name: Download requirements + run: sudo pip3 install xcrun && sudo pip3 install gcovr && sudo apt-get update && sudo apt-get install lcov libxrandr-dev libxcursor-dev libudev-dev libopenal-dev libflac-dev libvorbis-dev libgl1-mesa-dev libegl1-mesa-dev freeglut3-dev # OpenGL dependencies only needed for SFML + - name: Install dependencies + run: pip install -r requirements.txt + - name: Configure CMake + # Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make. + # See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type + run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DENABLE_COVERAGE=true + - name: Build + # Build your program with the given configuration + run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} + - name: Test + working-directory: ${{github.workspace}}/build + # Execute tests defined by the CMake configuration. + # See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail + run: ctest --output-on-failure + - name: clang-tidy + run: bash clang_tidy.sh #- name: get coverage # run: make coverage #- name: Run tests and collect coverage - # run: pytest --cov build/tests ${{ env.CODECOV_ATS_TESTS }} - - name: Upload coverage reports to Codecov - uses: codecov/codecov-action@v4.0.1 - with: - token: ${{ secrets.CODECOV_TOKEN }} - slug: CSRT-NTUA/AlgoPlus - - name: Upload to codecov - run: bash <(curl -s https://codecov.io/bash) \ No newline at end of file + # run: pytest --cov build/tests ${{ env.CODECOV_ATS_TESTS }}