ResInsight/.github/workflows/AppFwkUnitTest.yml

54 lines
2.1 KiB
YAML
Raw Normal View History

2020-03-15 13:28:33 -05:00
name: Application Framework Build with Unit Tests
on: [push, pull_request]
jobs:
ResInsight-x64:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest]
steps:
- name: Checkout
uses: actions/checkout@v2
2020-04-07 08:19:24 -05:00
- name: Cache Qt
2020-04-07 08:21:18 -05:00
id: cache-qt
uses: actions/cache@v2
2020-04-07 08:21:18 -05:00
with:
path: ${{ github.workspace }}/Qt/
2020-04-07 08:21:18 -05:00
key: ${{ runner.os }}-QtCache
- name: Install Qt
uses: jurplel/install-qt-action@v2
with:
version: 5.9.9
modules: qtscript
dir: '${{ github.workspace }}/Qt/'
2020-04-07 08:21:18 -05:00
cached: ${{ steps.cache-qt.outputs.cache-hit }}
2020-03-15 13:28:33 -05:00
- name: Install Linux dependencies
if: "contains( matrix.os, 'ubuntu')"
run: sudo apt-get install libxkbcommon-x11-0 libgl1-mesa-dev mesa-common-dev libglfw3-dev libglu1-mesa-dev
- name: Build AppFwk with Unit Tests
2020-04-07 08:26:42 -05:00
uses: lukka/run-cmake@v1
2020-03-15 13:28:33 -05:00
with:
cmakeListsOrSettingsJson: CMakeListsTxtAdvanced
cmakeListsTxtPath: '${{ github.workspace }}/Fwk/AppFwk/CMakeLists.txt'
cmakeAppendedArgs:
buildDirectory: ${{ github.workspace }}/cmakebuild
buildWithCMakeArgs: '--config Release'
useVcpkgToolchainFile: false
- name: Run Unit Tests Windows
if: contains( matrix.os, 'windows')
shell: bash
run: |
cmakebuild/cafProjectDataModel/cafPdmCore/cafPdmCore_UnitTests/Release/cafPdmCore_UnitTests
cmakebuild/cafProjectDataModel/cafPdmXml/cafPdmXml_UnitTests/Release/cafPdmXml_UnitTests
cmakebuild/cafProjectDataModel/cafProjectDataModel_UnitTests/Release/cafProjectDataModel_UnitTests
- name: Run Unit Tests Linux
if: "!contains( matrix.os, 'windows')"
shell: bash
run: |
cmakebuild/cafProjectDataModel/cafPdmCore/cafPdmCore_UnitTests/cafPdmCore_UnitTests
cmakebuild/cafProjectDataModel/cafPdmXml/cafPdmXml_UnitTests/cafPdmXml_UnitTests
cmakebuild/cafProjectDataModel/cafProjectDataModel_UnitTests/cafProjectDataModel_UnitTests
2020-04-07 08:35:09 -05:00