Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

460
Visualizações
How to test floating dialog boxes in cypress?

I am fairly new to cypress and practicing its functionalities on Facebook app. I am having an issue on testing these following scenarios:

  1. When clicked on First Name, this floating dialog should be visible.
  2. Validating the text in the dialog box to be 'What's your name?'.
cy.get('input[name="firstname"]').focused().then(($txt)=>{
            cy.get('[data-testid="undefined"]>.uiContextualLayer uiContextualLayerLeft>._5v-0 _53im>#js_18n').should('be.visible').and('contain',"What's your name?");
        });

But this is not working This is the pic that i am testing

Facebook sign up page

about 4 years ago · Juan Pablo Isaza
2 Respostas
Responde à pergunta

0

You can do something like this:

cy.get('[name="firstname"]').click()
cy.get('[name="lastname"]').click()
cy.get('[name="firstname"]').click() //triggers the error message
cy.contains('What\'s your name?').should('be.visible')
about 4 years ago · Juan Pablo Isaza Relatório

0

The popup is added to the end of the page after clicking the red icon.

cy.contains('div', 'First name')
  .parent()
  .next()    // red icon
  .click()
cy.contains('.uiContextualLayerPositioner', "What's you name?")
about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda