run_unit again #14
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: cca-ucvm-ci | |
| on: | |
| push: | |
| branches: [ main ] | |
| jobs: | |
| cca-build-ucvm-linux: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| python-version: [3.7] | |
| steps: | |
| - name: set UCVM_SRC_PATH | |
| run: echo "UCVM_SRC_PATH=$RUNNER_WORKSPACE/cca/ucvm" >> $GITHUB_ENV | |
| - name: set UCVM_INSTALL_PATH | |
| run: echo "UCVM_INSTALL_PATH=$RUNNER_WORKSPACE/cca/target" >> $GITHUB_ENV | |
| ### build ucvm(main) first | |
| - name: get-ucvm | |
| uses: actions/checkout@v2 | |
| with: | |
| repository: 'SCECcode/UCVM' | |
| ref: testMei | |
| path: ucvm | |
| - id: build-ucvm | |
| name: build ucvm | |
| uses: ./ucvm/.github/actions/build-ucvm-action | |
| with: | |
| initiating-repo: 'cca' | |
| target-model: 'cca' | |
| - name: get-result | |
| run: more ${{ steps.build-ucvm.outputs.build-log }} | |
| shell: bash | |
| - name: move stock cca away | |
| run: (rm -rf $RUNNER_WORKSPACE/cca/ucvm/work/model/cca) | |
| shell: bash | |
| ### build cca from github | |
| - name: checkout cca main | |
| uses: actions/checkout@v2 | |
| with: | |
| path: cca | |
| - name: move it to the right location | |
| run: (mv cca $RUNNER_WORKSPACE/cca/ucvm/work/model; pwd; ls) | |
| shell: bash | |
| - name: build cca as part of ucvm | |
| run: (cd $RUNNER_WORKSPACE/cca/ucvm/work/model/cca; ./.github/scripts/cca-build.sh) | |
| shell: bash | |
| ### check ucvm is still valid | |
| - name: check on ucvm | |
| run: (source $UCVM_INSTALL_PATH/conf/ucvm_env.sh; ucvm_query -H) | |
| shell: bash | |
| - name: test cca with ucvm | |
| run: (cd $RUNNER_WORKSPACE/cca/ucvm/work/model/cca; source $UCVM_INSTALL_PATH/conf/ucvm_env.sh; ./.github/scripts/cca-test-ucvm.sh) | |
| shell: bash | |
| - name: test cca under ucvm | |
| run: (cd $RUNNER_WORKSPACE/cca/ucvm; source $UCVM_INSTALL_PATH/conf/ucvm_env.sh; ./.github/scripts/ucvm-test.sh) | |
| shell: bash | |
| cca-build-ucvm-mac: | |
| runs-on: macos-latest | |
| strategy: | |
| matrix: | |
| python-version: [3.7] | |
| steps: | |
| - name: set UCVM_SRC_PATH | |
| run: echo "UCVM_SRC_PATH=$RUNNER_WORKSPACE/cca/ucvm" >> $GITHUB_ENV | |
| - name: set UCVM_INSTALL_PATH | |
| run: echo "UCVM_INSTALL_PATH=$RUNNER_WORKSPACE/cca/target" >> $GITHUB_ENV | |
| ### build ucvm(main) first | |
| - name: get-ucvm | |
| uses: actions/checkout@v2 | |
| with: | |
| repository: 'SCECcode/UCVM' | |
| ref: testMei | |
| path: ucvm | |
| - id: build-ucvm | |
| name: build ucvm | |
| uses: ./ucvm/.github/actions/build-ucvm-action | |
| with: | |
| initiating-repo: 'cca' | |
| target-model: 'cca' | |
| - name: get-result | |
| run: more ${{ steps.build-ucvm.outputs.build-log }} | |
| shell: bash | |
| - name: move stock cca away | |
| run: (rm -rf $RUNNER_WORKSPACE/cca/ucvm/work/model/cca) | |
| shell: bash | |
| ### build cca from github | |
| - name: checkout cca main | |
| uses: actions/checkout@v2 | |
| with: | |
| path: cca | |
| - name: move it to the right location | |
| run: (mv cca $RUNNER_WORKSPACE/cca/ucvm/work/model; pwd; ls) | |
| shell: bash | |
| - name: build cca as part of ucvm | |
| run: (cd $RUNNER_WORKSPACE/cca/ucvm/work/model/cca; ./.github/scripts/cca-build.sh) | |
| shell: bash | |
| ### check ucvm is still valid | |
| - name: check on ucvm | |
| run: (source $UCVM_INSTALL_PATH/conf/ucvm_env.sh; ucvm_query -H) | |
| shell: bash | |
| - name: test cca with ucvm | |
| run: (cd $RUNNER_WORKSPACE/cca/ucvm/work/model/cca; source $UCVM_INSTALL_PATH/conf/ucvm_env.sh; ./.github/scripts/cca-test-ucvm.sh) | |
| shell: bash | |
| - name: test cca under ucvm | |
| run: (cd $RUNNER_WORKSPACE/cca/ucvm; source $UCVM_INSTALL_PATH/conf/ucvm_env.sh; ./.github/scripts/ucvm-test.sh) | |
| shell: bash | |