From 1bce143aca27055b2806ade8bc2f236059d298b8 Mon Sep 17 00:00:00 2001 From: "mishal.alexander" Date: Thu, 4 Jan 2024 23:18:01 +0530 Subject: [PATCH] Parallel run with two jobs --- .github/workflows/parallel-test-build.yml | 29 +++++++++++++++++++++++ package.json | 3 ++- 2 files changed, 31 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/parallel-test-build.yml diff --git a/.github/workflows/parallel-test-build.yml b/.github/workflows/parallel-test-build.yml new file mode 100644 index 0000000..b01ba65 --- /dev/null +++ b/.github/workflows/parallel-test-build.yml @@ -0,0 +1,29 @@ +name: Regression End-to-end tests +on: push +jobs: + add-to-cart-run: + runs-on: ubuntu-22.04 + steps: + - name: Checkout + uses: actions/checkout@v3 + + # Install npm dependencies, cache them correctly + # and run all Cypress tests + + - name: Cypress run + uses: cypress-io/github-action@v5 + with: + command: npm run test:addToCart + register-flow-run: + runs-on: ubuntu-22.04 + steps: + - name: Checkout + uses: actions/checkout@v3 + + # Install npm dependencies, cache them correctly + # and run all Cypress tests + + - name: Cypress run + uses: cypress-io/github-action@v5 + with: + command: npm run test:registerTest \ No newline at end of file diff --git a/package.json b/package.json index 9931771..aca2a9a 100644 --- a/package.json +++ b/package.json @@ -4,7 +4,8 @@ "description": "Sample framework created using Cypress", "main": "index.js", "scripts": { - "test:addToCart": "npx cypress run --spec cypress/e2e/tests/addToCartTest.cy.js" + "test:addToCart": "npx cypress run --spec cypress/e2e/tests/addToCartTest.cy.js", + "test:registerTest": "npx cypress run --spec cypress/e2e/tests/registerTest.cy.js" }, "author": "Mishal Alexander", "repository": {