Skip to content

CI Cleanup

CI Cleanup #272

Workflow file for this run

name: MLSPP CI
on:
push:
branches:
- main
pull_request:
branches:
- main
env:
CMAKE_BUILD_PARALLEL_LEVEL: 3
CTEST_OUTPUT_ON_FAILURE: 1
VCPKG_BINARY_SOURCES: files,${{ github.workspace }}/vcpkg_cache,readwrite
CMAKE_TOOLCHAIN_FILE: ${{ github.workspace }}/vcpkg/scripts/buildsystems/vcpkg.cmake
jobs:
# formatting-check:
# name: Formatting Check
# runs-on: ubuntu-latest
# steps:
# - uses: actions/checkout@v4
#
# - name: Run clang-format style check for C/C++ programs
# uses: jidicula/clang-format-action@v4.11.0
# with:
# clang-format-version: 16
# include-regex: '^\./(src|include|test|cmd)/.*\.(cpp|h)$'
# fallback-style: 'Mozilla'
build-and-unit-test:
# needs: formatting-check
name: Build and test
runs-on: ${{ matrix.os }}
strategy:
matrix:
# os: [windows-latest, ubuntu-latest, macos-latest]
os: [windows-latest]
# crypto: [openssl_1.1, openssl_3, boringssl]
crypto: [openssl_1.1]
include:
- os: windows-latest
ctest-target: RUN_TESTS
# - os: ubuntu-latest
# ctest-target: test
# - os: macos-latest
# ctest-target: test
env:
BUILD_DIR: "${RUNNER_TEMP}/build_${{ matrix.crypto }}"
CRYPTO_DIR: "./alternatives/${{ matrix.crypto }}"
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
fetch-depth: 0
- uses: ./.github/actions/build
with:
cache-dir: ${{ github.workspace }}/vcpkg_cache
- name: Build
run: |
cmake -B "${{ env.BUILD_DIR }}" -DVCPKG_MANIFEST_DIR="${{ env.CRYPTO_DIR }}" -DTESTING=ON
cmake --build "${{ env.BUILD_DIR }}"
- name: Unit Test
run: |
cmake --build "${{ env.BUILD_DIR }}" --target "${{ matrix.ctest-target}}"
# interop-test:
# if: github.event.pull_request.draft == false
# needs: build-and-unit-test
# name: Interop test
# runs-on: ${{ matrix.os }}
# strategy:
# matrix:
# os: [ubuntu-latest]
# crypto: [openssl_1.1]
# include:
# - os: ubuntu-latest
# ctest-target: test
#
# env:
# BUILD_DIR: "${RUNNER_TEMP}/build_${{ matrix.crypto }}"
# CRYPTO_DIR: "./alternatives/${{ matrix.crypto }}"
#
# steps:
# - uses: actions/checkout@v4
# with:
# submodules: recursive
# fetch-depth: 0
#
# - uses: ./.github/actions/build
# with:
# cache-dir: ${{ github.workspace }}/vcpkg_cache
#
# - name: Build
# run: |
# cmake -B "${{ env.BUILD_DIR }}" -DVCPKG_MANIFEST_DIR="${{ env.CRYPTO_DIR }}"
# cmake --build "${{ env.BUILD_DIR }}"
#
# - name: Unit tests for test vector logic
# run: |
# ./${{ env.BUILD_DIR }}/lib/mls_vectors/test/mls_vectors_test
#
# - name: Build (Interop Harness)
# run: |
# cd cmd/interop
# cmake -B build
# cmake --build build
#
# - name: Test self-interop
# run: |
# make -C cmd/interop self-test
#
# - name: Test interop on test vectors
# run: |
# make -C cmd/interop interop-test
#
# - name: Test gRPC live interop with self
# run: |
# cd cmd/interop
# ./grpc-self-test.sh
#
# clang-tidy:
# if: github.event.pull_request.draft == false
# needs: build-and-unit-test
# name: Build with clang-tidy
# runs-on: ${{ matrix.os }}
# strategy:
# matrix:
# os: [ubuntu-latest]
# crypto: [openssl_1.1, openssl_3, boringssl]
#
# env:
# BUILD_DIR: "${RUNNER_TEMP}/build_${{ matrix.crypto }}"
# CRYPTO_DIR: "./alternatives/${{ matrix.crypto }}"
#
# steps:
# - uses: actions/checkout@v4
# with:
# submodules: recursive
# fetch-depth: 0
#
# - uses: ./.github/actions/build
# with:
# cache-dir: ${{ github.workspace }}/vcpkg_cache
#
# - name: Build with clang-tidy
# run: |
# cmake -B "${{ env.BUILD_DIR }}" -DVCPKG_MANIFEST_DIR="${{ env.CRYPTO_DIR }}" \
# -DTESTING=ON -DCLANG_TIDY=ON -DSANITIZERS=ON
# cmake --build "${{ env.BUILD_DIR }}"