Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • 02:26
    WinstonN commented #5949
  • 02:25
    WinstonN commented #5949
  • 00:26
    cypress[bot] commented #1359
  • 00:10
    brian-mann synchronize #1359
  • 00:10

    brian-mann on issue-1096-firefox-support

    Fix open_project_spec (#5946) Merge branch 'develop' into iss… set parallelization at 5 for dr… (compare)

  • 00:04
    zhammer commented #2918
  • 00:04
    zhammer commented #2918
  • Dec 15 21:57
    cypress[bot] commented #1359
  • Dec 15 21:43
    mr-winter commented #5602
  • Dec 15 21:41
    cypress[bot] commented #1359
  • Dec 15 21:37
    Bkucera synchronize #1359
  • Dec 15 21:37

    Bkucera on issue-1096-firefox-support

    actually add patch for patch-pa… (compare)

  • Dec 15 21:23
    vitodcampanelli commented #3975
  • Dec 15 21:22
    Bkucera synchronize #1359
  • Dec 15 21:22

    Bkucera on issue-1096-firefox-support

    fix e2e test script - patch sna… (compare)

  • Dec 15 21:12
    mr-winter commented #5602
  • Dec 15 21:11
    mr-winter commented #5602
  • Dec 15 18:40
    Bkucera commented #1486
  • Dec 15 18:38
    Bkucera commented #1684
  • Dec 15 16:34
    devinshoemaker commented #5776
David Luzar
@dwelle
@emilcardell that looks like your input has a disabled attribute set
Kapiira
@Kapiira
@dwelle Thanks for the help. Got it to work with cy.task
David Luzar
@dwelle
@Kapiira cool
Gleb Bahmutov
@bahmutov
Hey everyone, we have enabled threads in this room. So the best way to respond to a specific question or message is to hover over the right side of the message and pick "Start a thread"
Screen Shot 2019-11-08 at 10.29.41 AM.png
Jesús Moyano Doña
@ChusMoyano
Hello! :D
Jesús Moyano Doña
@ChusMoyano
Can someone help me with this?
jameseg
@jameseg
anyone having issues with tests failing when running in a container, but running just fine in the same environment outside of a container?
jameseg
@jameseg
i can't seem to get a test spec to be ignored using --config ignoreTestFiles='cypress/integration/sitecrawl/crawlsite.spec.js'
Morten Poulsen
@mspoulsen
Hi. I am working on setting up vue + cypress + typescript. Almost there I think.
I am using https://github.com/bahmutov/add-typescript-to-cypress/blob/master/src/cy-ts-preprocessor.js
My question: The preprocessor is loading all my jest test files. How can I exclude them?
Matt Mazzola
@mattmazzola

I noticed different behavior on tests when upgrading to 3.6.0 from 3.4.0. I saw the release notes mentioned "Mouse Improvements"
https://www.cypress.io/blog/2019/11/05/cypress-3-5-and-3-6-release/

It mentioned dbclick() and rightclick(). Was it possible that there were also changes to click() or was this unchanged?

Nate Johnson
@NateDawg90
Has anyone been able to use cy.request() and send formData?
David Luzar
@dwelle
@mattmazzola more events are now being triggered, and few minor fixes. Are you experiencing some issues?
@NateDawg90 what are you doing now?
Matt Mazzola
@mattmazzola

Yes, I had all my tests start by clicking a "Create Model" button that would open a modal where they could enter the name of the thing they were creating.
The modal never opens as if the button was never clicked. I can review the DOM snapshots in the Cypress runner and see it get the correct DOM node and the red circle for clicking center of button.

There also seems to be random errors of "runnable does not have id" that appear in 3.6.0 that never occurred in 3.4.0

Seems like a low level Mocha issue that shouldn't be possible
I rerun my tests and it eventually clicks the button and opens the modal like 1 out of 20 times which is not acceptable so I won't be upgrading until I understand why this is happening and how to fix it
The recording in chrome is cool feature though and we could use it
David Luzar
@dwelle
@mattmazzola is it happening in headless only?
Kyle Barr
@dark-swordsman

Hi there. I'm currently trying to do a test with a Stripe iframe and am having some trouble.

I found this issue that's over 3 years old. Specifically a kinda convoluted workaround in that issue that seems to kinda work I guess? https://github.com/cypress-io/cypress/issues/136#issuecomment-530806671

My issue is that I need to use xpath, which I have been using just fine up to this point, and I'm not sure if it's supported.

Edit: And just to show, this is what I tried, just to show the general idea. Not super familiar with wrap so this is probably wrong.

    // fill out CC form
    cy.xpath('//iframe[@name="stripe_checkout_app"]').then(($iframe) => {
      const $body = $iframe.contents().find('body');

      cy.wrap($body).xpath('//label[text()="Card number"]/following-sibling::input').type('4242424242424242');
      cy.wrap($body).xpath('//label[text()="Expiry"]/following-sibling::input').type('1234');
      cy.wrap($body).xpath('//label[text()="CVC"]/following-sibling::input').type('123');
      cy.wrap($body).xpath('//label[text()="ZIP Code"]/following-sibling::input').type('12345');

      cy.wrap($body).xpath('//div[@id="container"]/section/span[2]/div/div/main/form/nav/div/div/div/button[@type="submit"]').click();
    });
prudhvidandamudi
@prudhvidandamudi

@all, any idea how to use for loop and if else in cypress.
I was not able to find any document and stuck over an issue

https://stackoverflow.com/questions/58770726/using-for-loop-and-if-else-in-cypress

George Norris
@george-norris-salesforce

Test are always passing for us.

it('Deleting a unit shows the confirmation modal', async () => {

    cy.get('.data-delete-subcontent-btn').first().click({ force: true });

    cy.get('.slds-modal__container')
      .should('be.visible')
      .and('have.text', 'THIS DOES NOT EXIST ON THE PAGE');

This should fail. But is always passes.
Actually there is no green assert label on the test at all.
This tests a modal.

image.png
David Luzar
@dwelle
@george-norris-salesforce I don't like the async keyword.. to start with, remove the async from the function, see what happens then
Chris Divine
@csdivine
@prudhvidandamudi We use if else in a lot of our tests. Something like this seems to work for us:
if (username === 'admin') {
  cy.get(<element1>).click()
  } else {
    cy.get(<element2>).click()
  }
prudhvidandamudi
@prudhvidandamudi
@csdivine thanks for the reply, any idea how to mix it with for loop?
mariogara
@mariogara
Hi everyone. Does anyone knows if there is a spec/test owners tag in cypress? I haven't found anything about.
Galea Olimpiu
@olimpiu-galea
Hello
Do somebody knows why autocomplete doesn't work inside functions/ export module ?
rakeshchintareddy
@rakeshchintareddy
Hi All! Stubbing external rest calls is not working when baseUrl is https. No issues when baseUrl is http. Any special configuration is needed to achieve this?
Jeff Wells
@jeffmwells
Typescript question. I've added one custom command, and added the namespace declaration per the docs to the commands.ts file, but when the test runs the command is not recognized and the test fails. Any ideas?
Chau Tran
@nartc
@jeffmwells code?
Does anybody know how to get the following to work?
interface LoginFormInput {
   emailInput: Cypress.Chainable<JQuery<HTMLElement>>;
   passwordInput: Cypress.Chainable<JQuery<HTMLElement>>;
} 
function loginForm(): Cypress.Chainable<LoginFormInput> {
  return cy.wrap({
    emailInput: cy.get('email-input-selector'),
    passwordInput: cy.get('password-input-selector')
  });
}
David Luzar
@dwelle
@nartc cy commands are asynchronous (and also they're not promises, so the usual promise workflow won't work)
dunno how you use that code, tho - and what "doesn't work" exactly
Raymond Huang
@rhuang
Screen Shot 2019-11-10 at 12.16.57 PM.png
Hi all, I'm seeing instances where subsequent commands execute before the wait for the XHR request is finished waiting. Is this expected? I'm under the impression that cy.wait is blocking.
In the screenshot, it seems like (52) is executed before (51) is done waiting for the XHR.
Chau Tran
@nartc
@dwelle exactly what you're saying. Just don't know how to get the emailInput and passwordnput out of loginForm. I was doing: loginFormEmailInput() custom commands but the custom commands for some other forms are getting quite lengthy.
Michael Pinnegar
@Jazzepi
Has anyone had an issue with the chrome developer tools hiding itself immediately after you open them with F12? I'm running ubuntu 16.04 and Cypress 3.4.1
Michael Pinnegar
@Jazzepi
I updated Cypress and the problem went away. :green_heart:
marshuang-doudou
@marshuang-doudou
Has anyone use the cy.request to send one POST command with XML format body? if yes, could you pls share your body demo? thanks
Nikhil
@Nikhil_ECE_twitter
dpetrova
@dpetrova

Hi, I'm using Cypress with Vue. When I want to use async methods, cypress throw me error " D:\Vue_projects\ecap-hub\node_modules\@babel\runtime-corejs2\helpers\esm\asyncToGenerator.js:1
import _Promise from "../../core-js/promise";
^
ParseError: 'import' and 'export' may appear only with 'sourceType: module' "

Example:

Cypress.Commands.add('login', (username, password) => {  
  cy.window().then(async win => {
    await win.__store__.dispatch('user/login', { username, password })
  })  
})
David Luzar
@dwelle
@Nikhil_ECE_twitter nope. If the tab is being opened via window.open(), you'll have to intercept that and prevent it
Nikhil
@Nikhil_ECE_twitter
@dwelle window.open() it been used there, is there any workaround for that?
David Luzar
@dwelle
@Nikhil_ECE_twitter easiest is to disable it: cy.window().then( win => win.open = () = {})). But depending on what you're testing, you might want to spy on that replaced window.open.
jhangvar
@jhangvar
I'm getting a lot of these error messages "Cypress could not determine why this element 'XYZ' is not visible" using 3.6.0 and 3.6.1. Anyone recognize this?
David Luzar
@dwelle

@jhangvar never encountered this. It's a fallback message when Cypress cannot figure out why an element is hidden (source is here: https://github.com/cypress-io/cypress/blob/develop/packages/driver/src/dom/visibility.js#L383).

Funny - there's a TODO comment for one case, maybe it's your case?

  // TODO: need to add in the reason an element
  // is hidden when its fixed position and its
  // either being covered or there is no el
AFAIK cypress never expects the test function to return a promise (which async functions do) --- it expects to execute synchronously, and enqueue commands