https://cypress.io logo
Hi Dima, so for me this is working only thing is m...
# e2e-testing
m
Hi Dima, so for me this is working only thing is my google.ru does not give me yandex.by but it gives me yandex.com. Also yandex is annoying because it wants to check if i'm a bot
Copy code
js
describe("Testsuite with remove attr",()=>{

  it("remove attr",()=>{
    cy.setCookie("SOCS","CAISHAgBEhJnd3NfMjAyMjEwMTctMF9SQzMaAm5sIAEaBgiAiNKaBg",{
      domain: ".google.ru"
    })
    cy.visit("https://www.google.ru")

    cy.get("input[name=q]").type("Yandex{ENTER}");
    cy.get("a[href='https://yandex.com/']").first().invoke('removeAttr', 'target').click()
    cy.origin("https://yandex.com/", ()=> {
      cy.get( "form input[id=text]").type("byndyusoft{ENTER}");
      cy.get("a[href='https://byndyusoft.com/']").first().invoke('removeAttr', 'target').click()
    })

    cy.origin("https://byndyusoft.com/",()=>{
      cy.get("section div[class='know-more__container'] span:nth-child(2)").click()
    })
  })
})