File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed
Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ const FIXTURES = {
1313 USERS_COUNT : 1 ,
1414 CATEGORIES_COUNT : 2 ,
1515 CONTENT_COUNT : 2 ,
16- RESTAURANTS_COUNT : 2 ,
16+ RESTAURANTS_COUNT : 3 ,
1717}
1818
1919describe ( 'Meilisearch features' , ( ) => {
@@ -155,13 +155,15 @@ describe('Meilisearch features', () => {
155155 cy . wrap ( checkbox ) . click ( { force : true } )
156156 cy . wait ( '@addCollection' )
157157 cy . wait ( '@fetchCollections' ) // wait for the refetch after the POST
158+ } else {
159+ cy . fail ( 'The checkbox should not be checked' )
158160 }
159161 } )
160162
161163 // Re-select the row after the network sync to avoid stale element references
162- cy . get ( rowSelector )
163- . should ( 'contain.text' , 'Yes' )
164- . and ( 'contain.text' , 'Hooked' )
164+ // There can be delays until the state is updated, so wait for each separately
165+ cy . get ( rowSelector ) . contains ( 'Yes' ) // First, wait for the 'Yes' to appear
166+ cy . get ( rowSelector ) . contains ( 'Hooked' ) // Then, wait for the 'Hooked' to appear
165167 } )
166168 } )
167169
You can’t perform that action at this time.
0 commit comments