Dweather/conan build #344
This file contains hidden or 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: CMake workflow | |
| on: | |
| push: | |
| branches: [ "main" ] | |
| pull_request: | |
| branches: [ "main" ] | |
| jobs: | |
| Archon-build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install dependencies | |
| run: | | |
| ls -l | |
| .github/workflows/install-deps.sh | |
| shell: bash | |
| - name: Configure CMake for Archon Interface | |
| run: | | |
| cd ${{github.workspace}}/build | |
| rm -rf * | |
| cmake .. | |
| - name: Build | |
| run: | | |
| cd ${{github.workspace}}/build | |
| make | |
| make run_unit_tests | |
| - name: Run Unit Tests | |
| run: | | |
| cd ${{github.workspace}} | |
| bin/run_unit_tests | |
| - name: Start Emulator | |
| run: | | |
| cd ${{github.workspace}} | |
| bin/emulator Config/demo/demo.cfg -i generic & | |
| - name: Start camera-daemon | |
| run: | | |
| cd ${{github.workspace}} | |
| bin/camerad Config/demo/demo.cfg --foreground & | |
| - name: Run E2E tests | |
| run: | | |
| cd ${{github.workspace}} | |
| shopt -s expand_aliases | |
| alias cam="bin/socksend -h localhost -p 3031" | |
| function check { if [ $1 != "DONE" ]; then echo $1; exit 1; else echo $1; fi } | |
| command_open=$(cam open) | |
| check $command_open | |
| command_load=$(cam load) | |
| check $command_load | |
| command_expose=$(cam expose) | |
| check $command_expose | |
| command_printstatus=$(cam printstatus) | |
| check $command_printstatus |