Skip to content

Gx 21524 ✅ tools qa widgets dropdown select menu #342

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Jun 28, 2023
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/CI-Suite.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ jobs:
with:
browser: chrome
command: | #EDITAR AQUÍ EL ARCHIVO SUITE A EJECUTAR:
yarn file cypress/e2e/Tests/Elements/GX-20682-TextBoxFormSubmit.cy.js
yarn file cypress/e2e/Tests/Widgets/GX-21524-DropdownSelectMenu.cy.js

- name: ✅Import Test Results to Xray
if: always()
Expand All @@ -64,7 +64,7 @@ jobs:
password: ${{secrets.XRAY_CLIENT_SECRET}}
testFormat: 'junit' #OPCIONES PARA CAMBIAR: 'junit' (para xml) o 'cucumber' (para json)
testPaths: 'reports/test-results.xml' #OPCIONES: '/test-results.xml' o 'cucumber-report.json'
testExecKey: 'GX-20684' #EDITAR AQUÍ EL TEST EXECUTION A IMPORTAR LAS PRUEBAS.
testExecKey: 'GX-21526' #EDITAR AQUÍ EL TEST EXECUTION A IMPORTAR LAS PRUEBAS.
projectKey: 'GX' #EDITAR EN CASO DE TRABAJAR CON OTRO PROYECTO.

- name: 🔔Slack Notification of Done
Expand Down
47 changes: 47 additions & 0 deletions cypress/e2e/Tests/Widgets/GX-21524-DropdownSelectMenu.cy.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
import { removeLogs } from '@helper/RemoveLogs';
removeLogs();

describe('ToolsQA | Widgets | Dropdown - Select Menu', () => {
beforeEach('El usuario debe navegar al endpoint requerido', () => {
cy.visit('https://demoqa.com/select-menu');
cy.url().should('contain', 'select-menu');
});
it('GX-21525|TC1:Validar la funcionalidad del Dropdown “Select Value” al poder seleccionar correctamente una opción del mismo', () => {
cy.get('.css-1hwfws3').eq(0).click();
cy.get('#react-select-2-option-1-0').click();
cy.get('.css-1pahdxg-control').should('contain.text', 'Group 2, option 1');
});
it('GX-21525|TC2:Validar la funcionalidad del Dropdown “Select One” al poder seleccionar correctamente una opción del mismo', () => {
cy.get('.css-1hwfws3').eq(1).click();
cy.get('#react-select-3-option-0-4').click();
cy.get(':nth-child(4) > .col-md-6').should('contain.text', 'Prof.');
});
it('GX-21525|TC3:Validar la funcionalidad del Dropdown “Old Style Select Menu” al poder seleccionar correctamente una opción del mismo', () => {
cy.get('#oldSelectMenu').select('Black');
cy.get('#oldSelectMenu').should('have.value', '5');
});
it('GX-21525|TC4:Validar la funcionalidad del Dropdown “Multiselect drop down” al poder seleccionar correctamente más de una opción del mismo', () => {
cy.get('.css-1hwfws3').eq(2).click();
cy.get('.css-26l3qy-menu').find('#react-select-4-option-0').click();
cy.get('.css-26l3qy-menu').find('#react-select-4-option-1').click();
cy.get('.css-26l3qy-menu').find('#react-select-4-option-2').click();
cy.get('.css-26l3qy-menu').find('#react-select-4-option-3').click();
cy.get('.css-1pahdxg-control > .css-1hwfws3').should('have.text', 'GreenBlueBlackRed');
});
it('GX-21525|TC5:Validar que se visualice el atributo “No Options“ al seleccionar todas las opciones del Dropdown “Multiselect drop down”', () => {
cy.get('.css-1hwfws3').eq(2).click();
cy.get('.css-26l3qy-menu').find('#react-select-4-option-0').click();
cy.get('.css-26l3qy-menu').find('#react-select-4-option-1').click();
cy.get('.css-26l3qy-menu').find('#react-select-4-option-2').click();
cy.get('.css-26l3qy-menu').find('#react-select-4-option-3').click();
cy.get('.css-1gl4k7y').should('contain.text', 'No options');
});
it('GX-21525|TC6:Validar la funcionalidad del Dropdown “Standard Multi select” al poder seleccionar correctamente más de una opción del mismo', () => {
cy.get('select[name="cars"]').select(['Volvo', 'Audi', 'Saab', 'Opel']);
cy.get('select[name="cars"]').invoke('val').should('deep.equal', ['volvo', 'saab', 'opel', 'audi']);
cy.get('[value="volvo"]').should('be.selected');
cy.get('[value="saab"]').should('be.selected');
cy.get('[value="opel"]').should('be.selected');
cy.get('[value="audi"]').should('be.selected');
});
});
35 changes: 35 additions & 0 deletions cypress/test-plan/in-sprint/sprint-19/GX-21524.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
✅ACCEPTANCE CRITERIA

(This feature doesn’t need BDD AC - Please take a look into the BRS tab)

🚩BUSINESS RULES SPEC

Dropdowns: Select Value:

It’s a Dropdown with grouped options: Group 1 and Group 2 – to select one option

Select One:

It’s a simple React Dropdown – to select one option

Old Style Select Menu:

It’s an old Dropdown – to select one option

Multiselect drop down:

it’s a multiple selection; up to 4 options:

Green

Blue

Black

Red

IF all of the options are selected, “No Options” attribute should be displayed in the dropdown.

Standard multi select:

it’s a simple combo-box (Slots) that can be selected more than one.