@@ -32,6 +32,33 @@ describe('cloud debug test filtering', () => {
32
32
cy . get ( '.runnable-title' ) . contains ( 't4' )
33
33
} )
34
34
35
+ it ( 'wraps filter UI with large number of tests' , ( ) => {
36
+ cy . visitApp ( `specs/runner?file=cypress/e2e/lots-of-tests.cy.js` )
37
+
38
+ cy . get ( '[data-cy="reporter-panel"]' ) . as ( 'reporterPanel' )
39
+
40
+ cy . waitForSpecToFinish ( )
41
+
42
+ cy . withCtx ( ( ctx ) => {
43
+ ctx . coreData . cloud . testsForRunResults = [ 'test1' ]
44
+ } )
45
+
46
+ cy . visitApp ( `specs/runner?file=cypress/e2e/lots-of-tests.cy.js&runId=123` )
47
+ cy . waitForSpecToFinish ( { passCount : 50 } )
48
+
49
+ cy . get ( '@reporterPanel' ) . then ( ( el ) => el . width ( 500 ) )
50
+ cy . get ( '@reporterPanel' ) . percySnapshot ( 'wide' )
51
+
52
+ cy . get ( '@reporterPanel' ) . then ( ( el ) => el . width ( 350 ) )
53
+ cy . get ( '@reporterPanel' ) . percySnapshot ( 'medium' )
54
+
55
+ cy . get ( '@reporterPanel' ) . then ( ( el ) => el . width ( 250 ) )
56
+ cy . get ( '@reporterPanel' ) . percySnapshot ( 'narrow' )
57
+
58
+ cy . get ( '@reporterPanel' ) . then ( ( el ) => el . width ( 150 ) )
59
+ cy . get ( '@reporterPanel' ) . percySnapshot ( 'skinny' )
60
+ } )
61
+
35
62
it ( 'works with skips and onlys' , ( ) => {
36
63
cy . visitApp ( `specs/runner?file=cypress/e2e/skip-and-only.cy.js` )
37
64
@@ -94,4 +121,19 @@ describe('cloud debug test filtering', () => {
94
121
cy . get ( '.runnable-title' ) . eq ( 1 ) . contains ( 's1 (skipped due to browser)' )
95
122
cy . get ( '.runnable-title' ) . eq ( 2 ) . contains ( 't2' )
96
123
} )
124
+
125
+ it ( 'filter is maintained across cross-domain reinitialization' , ( ) => {
126
+ cy . visitApp ( `specs/runner?file=cypress/e2e/domain-change.cy.js` )
127
+
128
+ cy . get ( '[data-cy="reporter-panel"]' ) . as ( 'reporterPanel' )
129
+
130
+ cy . waitForSpecToFinish ( )
131
+
132
+ cy . withCtx ( ( ctx ) => {
133
+ ctx . coreData . cloud . testsForRunResults = [ 't2' , 't3' ]
134
+ } )
135
+
136
+ cy . visitApp ( `specs/runner?file=cypress/e2e/domain-change.cy.js&runId=123` )
137
+ cy . waitForSpecToFinish ( { failCount : 2 } )
138
+ } )
97
139
} )
0 commit comments