Browse Source

test: cy screenshot experiment over ci-cd

Signed-off-by: Raju Udava <86527202+dstala@users.noreply.github.com>
pull/1127/head
Raju Udava 3 years ago
parent
commit
7d6adaaf52
  1. 96
      .github/workflows/ci-cd.yml
  2. 3
      scripts/cypress/integration/common/6d_language_validation.js

96
.github/workflows/ci-cd.yml

@ -44,6 +44,12 @@ jobs:
${{ runner.os }}-
- name: Set env
run: echo "NODE_ENV=test" >> $GITHUB_ENV
- name: Upload screenshots
uses: actions/upload-artifact@latest
if: failure()
with:
name: cypress-snapshots
path: cypress/snapshots
- name: Cypress run
uses: cypress-io/github-action@v2
with:
@ -82,6 +88,12 @@ jobs:
- name: Set env
run: echo "NODE_ENV=test" >> $GITHUB_ENV
- name: Upload screenshots
uses: actions/upload-artifact@latest
if: failure()
with:
name: cypress-snapshots
path: cypress/snapshots
- name: Cypress run
uses: cypress-io/github-action@v2
with:
@ -120,6 +132,12 @@ jobs:
- name: Set env
run: echo "NODE_ENV=test" >> $GITHUB_ENV
- name: Upload screenshots
uses: actions/upload-artifact@latest
if: failure()
with:
name: cypress-snapshots
path: cypress/snapshots
- name: Cypress run
uses: cypress-io/github-action@v2
with:
@ -158,6 +176,12 @@ jobs:
- name: Set env
run: echo "NODE_ENV=test" >> $GITHUB_ENV
- name: Upload screenshots
uses: actions/upload-artifact@latest
if: failure()
with:
name: cypress-snapshots
path: cypress/snapshots
- name: Cypress run
uses: cypress-io/github-action@v2
with:
@ -195,6 +219,12 @@ jobs:
${{ runner.os }}-
- name: Set env
run: echo "NODE_ENV=test" >> $GITHUB_ENV
- name: Upload screenshots
uses: actions/upload-artifact@latest
if: failure()
with:
name: cypress-snapshots
path: cypress/snapshots
- name: Cypress run
uses: cypress-io/github-action@v2
with:
@ -233,6 +263,12 @@ jobs:
- name: Set env
run: echo "NODE_ENV=test" >> $GITHUB_ENV
- name: Upload screenshots
uses: actions/upload-artifact@latest
if: failure()
with:
name: cypress-snapshots
path: cypress/snapshots
- name: Cypress run
uses: cypress-io/github-action@v2
with:
@ -271,6 +307,12 @@ jobs:
- name: Set env
run: echo "NODE_ENV=test" >> $GITHUB_ENV
- name: Upload screenshots
uses: actions/upload-artifact@latest
if: failure()
with:
name: cypress-snapshots
path: cypress/snapshots
- name: Cypress run
uses: cypress-io/github-action@v2
with:
@ -309,6 +351,12 @@ jobs:
- name: Set env
run: echo "NODE_ENV=test" >> $GITHUB_ENV
- name: Upload screenshots
uses: actions/upload-artifact@latest
if: failure()
with:
name: cypress-snapshots
path: cypress/snapshots
- name: Cypress run
uses: cypress-io/github-action@v2
with:
@ -347,6 +395,12 @@ jobs:
- name: Set env
run: echo "NODE_ENV=test" >> $GITHUB_ENV
- name: Upload screenshots
uses: actions/upload-artifact@latest
if: failure()
with:
name: cypress-snapshots
path: cypress/snapshots
- name: Cypress run
uses: cypress-io/github-action@v2
with:
@ -385,6 +439,12 @@ jobs:
- name: Set env
run: echo "NODE_ENV=test" >> $GITHUB_ENV
- name: Upload screenshots
uses: actions/upload-artifact@latest
if: failure()
with:
name: cypress-snapshots
path: cypress/snapshots
- name: Cypress run
uses: cypress-io/github-action@v2
with:
@ -423,6 +483,12 @@ jobs:
- name: Set env
run: echo "NODE_ENV=test" >> $GITHUB_ENV
- name: Upload screenshots
uses: actions/upload-artifact@latest
if: failure()
with:
name: cypress-snapshots
path: cypress/snapshots
- name: Cypress run
uses: cypress-io/github-action@v2
with:
@ -461,6 +527,12 @@ jobs:
- name: Set env
run: echo "NODE_ENV=test" >> $GITHUB_ENV
- name: Upload screenshots
uses: actions/upload-artifact@latest
if: failure()
with:
name: cypress-snapshots
path: cypress/snapshots
- name: Cypress run
uses: cypress-io/github-action@v2
with:
@ -499,6 +571,12 @@ jobs:
- name: Set env
run: echo "NODE_ENV=test" >> $GITHUB_ENV
- name: Upload screenshots
uses: actions/upload-artifact@latest
if: failure()
with:
name: cypress-snapshots
path: cypress/snapshots
- name: Cypress run
uses: cypress-io/github-action@v2
with:
@ -537,6 +615,12 @@ jobs:
- name: Set env
run: echo "NODE_ENV=test" >> $GITHUB_ENV
- name: Upload screenshots
uses: actions/upload-artifact@latest
if: failure()
with:
name: cypress-snapshots
path: cypress/snapshots
- name: Cypress run
uses: cypress-io/github-action@v2
with:
@ -575,6 +659,12 @@ jobs:
- name: Set env
run: echo "NODE_ENV=test" >> $GITHUB_ENV
- name: Upload screenshots
uses: actions/upload-artifact@latest
if: failure()
with:
name: cypress-snapshots
path: cypress/snapshots
- name: Cypress run
uses: cypress-io/github-action@v2
with:
@ -613,6 +703,12 @@ jobs:
- name: Set env
run: echo "NODE_ENV=test" >> $GITHUB_ENV
- name: Upload screenshots
uses: actions/upload-artifact@latest
if: failure()
with:
name: cypress-snapshots
path: cypress/snapshots
- name: Cypress run
uses: cypress-io/github-action@v2
with:

3
scripts/cypress/integration/common/6d_language_validation.js

@ -9,6 +9,7 @@ export const genTest = (type, xcdb) => {
before(() => {
//loginPage.signIn(roles.owner.credentials)
mainPage.toolBarTopLeft(mainPage.HOME).click();
cy.screenshot("6d-1");
});
const langVerification = (idx, lang) => {
@ -20,6 +21,8 @@ export const genTest = (type, xcdb) => {
cy.get(".nc-menu-translate").click();
cy.getActiveMenu().find(".v-list-item").eq(idx).click();
cy.screenshot("6d-2");
// basic validations
// 1. Page title: "My Projects"
// 2. Button: "New Project"

Loading…
Cancel
Save