git.delta.rocks / unique-network / refs/commits / 35d50c165268

difftreelog

Node-only update: run tests in parallel

Max Andreev2022-12-02parent: #c8ad2c2.patch.diff
in: master

1 file changed

modified.github/workflows/node-only-update.ymldiffbeforeafterboth
160 ref: ${{ matrix.mainnet_branch }} #Checking out head commit160 ref: ${{ matrix.mainnet_branch }} #Checking out head commit
161 path: ${{ matrix.mainnet_branch }}161 path: ${{ matrix.mainnet_branch }}
162162
163 - name: Run tests before Node Parachain upgrade163 - name: Run Parallel tests before Node Parachain upgrade
164 working-directory: ${{ matrix.mainnet_branch }}/tests164 working-directory: ${{ matrix.mainnet_branch }}/tests
165 if: success() || failure()
165 run: |166 run: |
166 yarn install167 yarn install
167 yarn add mochawesome168 yarn add mochawesome
168 node scripts/readyness.js169 node scripts/readyness.js
169 echo "Ready to start tests"170 echo "Ready to start tests"
170 yarn polkadot-types171 yarn polkadot-types
171 NOW=$(date +%s) && yarn test --reporter mochawesome --reporter-options reportFilename=test-before-${NOW}172 NOW=$(date +%s) && yarn testParallel --reporter mochawesome --reporter-options reportFilename=test-parallel-${NOW}
172 env:173 env:
173 RPC_URL: http://127.0.0.1:9933/174 RPC_URL: http://127.0.0.1:9933/
175
176 # - name: Upload Parallel Test Report Before Node upgrade
177 # uses: phoenix-actions/test-reporting@v8
178 # id: test-parallel-report-before
179 # if: success() || failure() # run this step even if previous step failed
180 # with:
181 # name: Tests before node upgrade ${{ matrix.network }} # Name of the check run which will be created
182 # path: ${{ matrix.mainnet_branch }}/tests/mochawesome-report/test-parallel-*.json # Path to test results
183 # reporter: mochawesome-json
184 # fail-on-error: 'false'
174185
175 - name: Upload Test Report Before Node upgrade186 - name: Run Sequential tests before Node Parachain upgrade
176 uses: phoenix-actions/test-reporting@v8
177 id: test-report-before
178 if: success() || failure() # run this step even if previous step failed187 if: success() || failure()
179 with:
180 name: Tests before node upgrade ${{ matrix.network }} # Name of the check run which will be created
181 path: ${{ matrix.mainnet_branch }}/tests/mochawesome-report/test-before-*.json # Path to test results188 working-directory: ${{ matrix.mainnet_branch }}/tests
182 reporter: mochawesome-json189 run: NOW=$(date +%s) && yarn testSequential --reporter mochawesome --reporter-options reportFilename=test-sequential-${NOW}
183 fail-on-error: 'false'190 env:
184 token: ${{ secrets.GITHUB_TOKEN }}191 RPC_URL: http://127.0.0.1:9933/
185
186 # TODO uncomment thease steps after the merge
187 #- name: Run Parallel tests before Node Parachain upgrade
188 # working-directory: ${{ matrix.mainnet_branch }}/tests
189 # run: |
190 # yarn install
191 # yarn add mochawesome
192 # echo "Ready to start tests"
193 # yarn polkadot-types
194 # NOW=$(date +%s) && yarn testParallel --reporter mochawesome --reporter-options reportFilename=test-parallel-${NOW}
195 # env:
196 # RPC_URL: http://127.0.0.1:9933/
197
198 #- name: Upload Parallel Test Report Before Node upgrade
199 # uses: phoenix-actions/test-reporting@v8
200 # id: test-parallel-report-before
201 # if: success() || failure() # run this step even if previous step failed
202 # with:
203 # name: Tests before node upgrade ${{ matrix.network }} # Name of the check run which will be created
204 # path: ${{ matrix.mainnet_branch }}/tests/mochawesome-report/test-parallel-*.json # Path to test results
205 # reporter: mochawesome-json
206 # fail-on-error: 'false'
207
208 # - name: Run Sequential tests before Node Parachain upgrade
209 # if: success() || failure()
210 # working-directory: ${{ matrix.mainnet_branch }}/tests
211 # run: NOW=$(date +%s) && yarn testSequential --reporter mochawesome --reporter-options reportFilename=test-sequential-${NOW}
212 # env:
213 # RPC_URL: http://127.0.0.1:9933/
214192
215 # - name: Upload Sequential Test Report Before Node upgrade193 # - name: Upload Sequential Test Report Before Node upgrade
216 # uses: phoenix-actions/test-reporting@v8194 # uses: phoenix-actions/test-reporting@v8
305 exit 0283 exit 0
306 shell: bash284 shell: bash
307285
308 ## TODO: Remove next two blocks before switch to Parrallel & Sequental tests. Uncoment commented blocks.286 - name: Run Parallel tests after Node Parachain upgrade
287 working-directory: ${{ matrix.mainnet_branch }}/tests
288 if: success() || failure() # run this step even if previous step failed
289 run: |
290 yarn install
291 yarn add mochawesome
292 node scripts/readyness.js
293 echo "Ready to start tests"
294 yarn polkadot-types
295 NOW=$(date +%s) && yarn testParallel --reporter mochawesome --reporter-options reportFilename=test-parallel-${NOW}
296 env:
297 RPC_URL: http://127.0.0.1:9933/
298
299 #- name: Test Report Parallel After Node upgrade
300 # uses: phoenix-actions/test-reporting@v8
301 # id: test-report-parallel-after
302 # if: success() || failure() # run this step even if previous step failed
303 # with:
304 # name: Tests after node upgrade ${{ matrix.network }} # Name of the check run which will be created
305 # path: ${{ matrix.mainnet_branch }}/tests/mochawesome-report/test-parallel-*.json # Path to test results
306 # reporter: mochawesome-json
307 # fail-on-error: 'false'
308
309 - name: Run tests after Node Parachain upgrade309 - name: Run Sequential tests after Node Parachain upgrade
310 if: success() || failure() # run this step even if previous step failed310 if: success() || failure()
311 working-directory: ${{ matrix.mainnet_branch }}/tests311 working-directory: ${{ matrix.mainnet_branch }}/tests
312 run: |312 run: NOW=$(date +%s) && yarn testSequential --reporter mochawesome --reporter-options reportFilename=test-sequential-${NOW}
313 yarn install
314 yarn add mochawesome
315 node scripts/readyness.js
316 echo "Ready to start tests"
317 yarn polkadot-types
318 NOW=$(date +%s) && yarn test --reporter mochawesome --reporter-options reportFilename=test-after-${NOW}
319 env:313 env:
320 RPC_URL: http://127.0.0.1:9933/314 RPC_URL: http://127.0.0.1:9933/
321
322 # - name: Test Report After Node upgrade
323 # uses: phoenix-actions/test-reporting@v8
324 # id: test-report-after
325 # if: success() || failure() # run this step even if previous step failed
326 # with:
327 # name: Tests after node upgrade ${{ matrix.network }} # Name of the check run which will be created
328 # path: ${{ matrix.mainnet_branch }}/tests/mochawesome-report/test-after-*.json # Path to test results
329 # reporter: mochawesome-json
330 # fail-on-error: 'false'
331 # token: ${{ secrets.GITHUB_TOKEN }}
332
333 # TODO uncomment thease steps after the merge
334 #- name: Run Parallel tests after Node Parachain upgrade
335 # working-directory: ${{ matrix.mainnet_branch }}/tests
336 # run: |
337 # yarn install
338 # yarn add mochawesome
339 # node scripts/readyness.js
340 # echo "Ready to start tests"
341 # yarn polkadot-types
342 # NOW=$(date +%s) && yarn testParallel --reporter mochawesome --reporter-options reportFilename=test-parallel-${NOW}
343 # env:
344 # RPC_URL: http://127.0.0.1:9933/
345
346 #- name: Test Report Parallel After Node upgrade
347 # uses: phoenix-actions/test-reporting@v8
348 # id: test-report-parallel-after
349 # if: success() || failure() # run this step even if previous step failed
350 # with:
351 # name: Tests after node upgrade ${{ matrix.network }} # Name of the check run which will be created
352 # path: ${{ matrix.mainnet_branch }}/tests/mochawesome-report/test-parallel-*.json # Path to test results
353 # reporter: mochawesome-json
354 # fail-on-error: 'false'
355
356 #- name: Run Sequential tests after Node Parachain upgrade
357 # if: success() || failure()
358 # working-directory: ${{ matrix.mainnet_branch }}/tests
359 # run: NOW=$(date +%s) && yarn testSequential --reporter mochawesome --reporter-options reportFilename=test-sequential-${NOW}
360 # env:
361 # RPC_URL: http://127.0.0.1:9933/
362315
363 #- name: Upload Sequential Test Report After Node upgrade316 #- name: Upload Sequential Test Report After Node upgrade
364 # uses: phoenix-actions/test-reporting@v8317 # uses: phoenix-actions/test-reporting@v8