1name: yarn test dev234on:5 6 workflow_call:78910env:11 REPO_URL: ${{ github.server_url }}/${{ github.repository }}12131415161718jobs:19 20 dev_build_int_tests:21 22 runs-on: [self-hosted-ci,medium]23 timeout-minutes: 13802425 name: ${{ matrix.network }}2627 continue-on-error: true 2829 strategy:30 matrix:31 include:32 - network: "opal"33 features: "opal-runtime"34 - network: "quartz"35 features: "quartz-runtime"36 - network: "unique"37 features: "unique-runtime"3839 steps:4041 - name: Clean Workspace42 uses: AutoModality/action-clean@v1.1.04344 45 - uses: actions/checkout@v346 with:47 ref: ${{ github.head_ref }} 4849 - name: Read .env file50 uses: xom9ikk/dotenv@v1.0.25152 - name: Generate ENV related extend file for docker-compose53 uses: cuchi/jinja2-action@v1.2.054 with:55 template: .docker/docker-compose.tmp-dev.j256 output_file: .docker/docker-compose.${{ matrix.network }}.yml57 variables: |58 RUST_TOOLCHAIN=${{ env.RUST_TOOLCHAIN }}59 FEATURE=${{ matrix.features }}60 6162 - name: Show build configuration63 run: cat .docker/docker-compose.${{ matrix.network }}.yml6465 - name: Build the stack66 run: docker-compose -f ".docker/docker-compose-dev.yaml" -f ".docker/docker-compose.${{ matrix.network }}.yml" up -d --build --remove-orphans6768 - uses: actions/setup-node@v369 with:70 node-version: 167172 - name: Run tests73 run: |74 cd tests75 yarn install76 yarn add mochawesome77 echo "Ready to start tests"78 NOW=$(date +%s) && yarn test --reporter mochawesome --reporter-options reportFilename=test-${NOW}79 env:80 RPC_URL: http://127.0.0.1:9933/8182 - name: Test Report83 uses: phoenix-actions/test-reporting@v884 id: test-report85 if: success() || failure() 86 with:87 name: int test results - ${{ matrix.network }} 88 path: tests/mochawesome-report/test-*.json 89 reporter: mochawesome-json90 fail-on-error: 'false'9192 - name: Read output variables93 run: |94 echo "url is ${{ steps.test-report.outputs.runHtmlUrl }}"9596 - name: Stop running containers97 if: always() 98 run: docker-compose -f ".docker/docker-compose-dev.yaml" -f ".docker/docker-compose.${{ matrix.network }}.yml" down