Try build/test on Windows using github action #65
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Test SimpleIni | |
on: | |
push: | |
branches: [ master ] | |
pull_request: | |
branches: [ master ] | |
jobs: | |
Windows: | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install requirements | |
run: | | |
choco install nuget.commandline -y | |
nuget restore simpleini.sln | |
- run: msbuild simpleini.sln /p:Configuration=Release | |
- name: Run Tests | |
run: | | |
cd vcproj\x64\Release | |
.\tests.exe | |
Ubuntu: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Install requirements | |
run: sudo apt install libgtest-dev cmake | |
- uses: actions/checkout@v3 | |
- run: make all && make test | |
- name: test with CMake (-DSIMPLEINI_USE_SYSTEM_GTEST=OFF) | |
run: | | |
cmake . -B build -DSIMPLEINI_USE_SYSTEM_GTEST=OFF | |
cmake --build build | |
ctest --test-dir build | |
- name: test with CMake (-DSIMPLEINI_USE_SYSTEM_GTEST=ON) | |
run: | | |
cmake . -B build-system-gtest -DSIMPLEINI_USE_SYSTEM_GTEST=ON | |
cmake --build build-system-gtest | |
ctest --test-dir build-system-gtest | |
MacOS: | |
runs-on: macos-latest | |
steps: | |
- name: Install requirements | |
run: brew install googletest cmake | |
- uses: actions/checkout@v3 | |
- run: make all && make test | |
- name: test with CMake (-DSIMPLEINI_USE_SYSTEM_GTEST=OFF) | |
run: | | |
cmake . -B build -DSIMPLEINI_USE_SYSTEM_GTEST=OFF | |
cmake --build build | |
ctest --test-dir build | |
- name: test with CMake (-DSIMPLEINI_USE_SYSTEM_GTEST=ON) | |
run: | | |
cmake . -B build-system-gtest -DSIMPLEINI_USE_SYSTEM_GTEST=ON | |
cmake --build build-system-gtest | |
ctest --test-dir build-system-gtest |