Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.Sign up
Indicate when XHR's match aliases multiple times, and correlate those to waits #477
There's not an easy to know or correlate multiple matched XHR aliases to knowing how to wait for them.
Here's an example screenshot:
The problem is that the user is trying to wait on the 2nd XHR. But since they've only added a single
When an XHR matches an alias multiple times we should add a number indicator next to it...
So then when adding code like:
cy .wait("@getTable") .wait("@getTable") .wait("@getTable")
The command log would actually look like:
@bsmithEG There actually is an undocumented way to check the number of times an XHR was responsed to using
cy.wait('@getRuns') cy.tick(10000) // should have done 2 request responses, and definitely not 3 cy.get('@getRuns.all').should('have.length', 2)
referenced this issue
Dec 3, 2018
I think that the numbers by themselves is a bit tricky because it's so close to the stylings for when we print the number of elements found for a command.
But I also think that the ordinal numbers are very English-centric, as ordinals are printed differently in each language. They also take up more room, which is a negative.
I would also make sure that you take into account there being 3 digit numbers - someone will have 100+ requests
Maybe an alternative would be to write the number beside the printed alias...so:
@jennifer-shehane if you can experiment with some of the designs...
I'm kind of thinking of something like this...
I think we should connect the "number" with the alias, and tweak the tooltip messaging. Offering a "(?)" link next to alias also might be a good idea to help communicate how this actually works.
PR'd in #2960, screenshots of that below.
One topic I'm not sure on:
Some topics we discussed but I didn't implement: