difftreelog
test remove execution readyness check script
in: master
1 file changed
.github/workflows/dev-build-tests_v2.ymldiffbeforeafterboth1name: yarn test dev23# Controls when the action will run.4on:5 # Triggers the workflow on push or pull request events but only for the master branch6 workflow_call:789#Define Workflow variables10env:11 REPO_URL: ${{ github.server_url }}/${{ github.repository }}1213#concurrency: 14# group: ${{ github.workflow }}-${{ github.head_ref }}15# cancel-in-progress: true1617# A workflow run is made up of one or more jobs that can run sequentially or in parallel18jobs:19 20 dev_build_int_tests:21 # The type of runner that the job will run on22 runs-on: [self-hosted-ci,medium]23 timeout-minutes: 13802425 name: ${{ matrix.network }}2627 continue-on-error: true #Do not stop testing of matrix runs failed. As it decided during PR review - it required 50/50& Let's check it with false.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:40 - name: Skip if pull request is in Draft41 # `if: github.event.pull_request.draft == true` should be kept here, at42 # the step level, rather than at the job level. The latter is not43 # recommended because when the PR is moved from "Draft" to "Ready to44 # review" the workflow will immediately be passing (since it was skipped),45 # even though it hasn't actually ran, since it takes a few seconds for46 # the workflow to start. This is also disclosed in:47 # https://github.community/t/dont-run-actions-on-draft-pull-requests/16817/1748 # That scenario would open an opportunity for the check to be bypassed:49 # 1. Get your PR approved50 # 2. Move it to Draft51 # 3. Push whatever commits you want52 # 4. Move it to "Ready for review"; now the workflow is passing (it was53 # skipped) and "Check reviews" is also passing (it won't be updated54 # until the workflow is finished)55 if: github.event.pull_request.draft == true56 run: exit 15758 - name: Clean Workspace59 uses: AutoModality/action-clean@v1.1.06061 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it62 - uses: actions/checkout@v363 with:64 ref: ${{ github.head_ref }} #Checking out head commit6566 - name: Read .env file67 uses: xom9ikk/dotenv@v1.0.26869 - name: Generate ENV related extend file for docker-compose70 uses: cuchi/jinja2-action@v1.2.071 with:72 template: .docker/docker-compose.tmp-dev.j273 output_file: .docker/docker-compose.${{ matrix.network }}.yml74 variables: |75 RUST_TOOLCHAIN=${{ env.RUST_TOOLCHAIN }}76 FEATURE=${{ matrix.features }}77 7879 - name: Show build configuration80 run: cat .docker/docker-compose.${{ matrix.network }}.yml8182 - name: Build the stack83 run: docker-compose -f ".docker/docker-compose-dev.yaml" -f ".docker/docker-compose.${{ matrix.network }}.yml" up -d --build --remove-orphans8485 - uses: actions/setup-node@v386 with:87 node-version: 168889 - name: Run tests90 run: |91 cd tests92 yarn install93 yarn add mochawesome94 echo "Ready to start tests"95 node scripts/readyness.js96 NOW=$(date +%s) && yarn test --reporter mochawesome --reporter-options reportFilename=test-${NOW}97 env:98 RPC_URL: http://127.0.0.1:9933/99100 - name: Test Report101 uses: phoenix-actions/test-reporting@v8102 id: test-report103 if: success() || failure() # run this step even if previous step failed104 with:105 name: int test results - ${{ matrix.network }} # Name of the check run which will be created106 path: tests/mochawesome-report/test-*.json # Path to test results107 reporter: mochawesome-json108 fail-on-error: 'false'109110 - name: Read output variables111 run: |112 echo "url is ${{ steps.test-report.outputs.runHtmlUrl }}"113114 - name: Stop running containers115 if: always() # run this step always116 run: docker-compose -f ".docker/docker-compose-dev.yaml" -f ".docker/docker-compose.${{ matrix.network }}.yml" down1name: yarn test dev23# Controls when the action will run.4on:5 # Triggers the workflow on push or pull request events but only for the master branch6 workflow_call:789#Define Workflow variables10env:11 REPO_URL: ${{ github.server_url }}/${{ github.repository }}1213#concurrency: 14# group: ${{ github.workflow }}-${{ github.head_ref }}15# cancel-in-progress: true1617# A workflow run is made up of one or more jobs that can run sequentially or in parallel18jobs:19 20 dev_build_int_tests:21 # The type of runner that the job will run on22 runs-on: [self-hosted-ci,medium]23 timeout-minutes: 13802425 name: ${{ matrix.network }}2627 continue-on-error: true #Do not stop testing of matrix runs failed. As it decided during PR review - it required 50/50& Let's check it with false.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 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it45 - uses: actions/checkout@v346 with:47 ref: ${{ github.head_ref }} #Checking out head commit4849 - 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() # run this step even if previous step failed86 with:87 name: int test results - ${{ matrix.network }} # Name of the check run which will be created88 path: tests/mochawesome-report/test-*.json # Path to test results89 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() # run this step always98 run: docker-compose -f ".docker/docker-compose-dev.yaml" -f ".docker/docker-compose.${{ matrix.network }}.yml" down