@@ -440,7 +440,9 @@ describe("Job Monitor", () => {
440440
441441 cy . get ( "[data-testid=search-field]" ) . type ( "ID{enter}={enter}1{enter}" ) ;
442442
443- cy . get ( '[role="group"]' ) . find ( "button" ) . should ( "have.length" , 5 ) ;
443+ cy . get ( '[data-testid="search-bar"]' )
444+ . find ( ".MuiChip-root" )
445+ . should ( "have.length" , 3 ) ;
444446 } ) ;
445447
446448 it ( "should handle filter editing" , ( ) => {
@@ -449,19 +451,26 @@ describe("Job Monitor", () => {
449451 cy . get ( "[data-testid=search-field]" ) . type ( "ID{enter}={enter}1{enter}" ) ;
450452
451453 cy . get ( "[data-testid=search-field]" ) . type ( "{leftArrow}2{enter}" ) ;
452- cy . get ( '[role="group"]' ) . find ( "button" ) . contains ( "12" ) . should ( "exist" ) ;
454+ cy . get ( '[data-testid="search-bar"]' )
455+ . find ( ".MuiChip-root" )
456+ . contains ( "12" )
457+ . should ( "exist" ) ;
453458 } ) ;
454459
455460 it ( "should handle filter clear" , ( ) => {
456461 cy . get ( "table" ) . should ( "be.visible" ) ;
457462
458463 cy . get ( "[data-testid=search-field]" ) . type ( "ID{enter}={enter}1{enter}" ) ;
459464
460- cy . get ( '[role="group"]' ) . find ( "button" ) . should ( "have.length" , 5 ) ;
465+ cy . get ( '[data-testid="search-bar"]' )
466+ . find ( ".MuiChip-root" )
467+ . should ( "have.length" , 3 ) ;
461468
462469 cy . get ( '[data-testid="DeleteIcon"]' ) . click ( ) ;
463470
464- cy . get ( '[role="group"]' ) . find ( "button" ) . should ( "have.length" , 2 ) ;
471+ cy . get ( '[data-testid="search-bar"]' )
472+ . find ( ".MuiChip-root" )
473+ . should ( "have.length" , 0 ) ;
465474 } ) ;
466475
467476 it ( "should handle filter apply and persist" , ( ) => {
@@ -480,8 +489,13 @@ describe("Job Monitor", () => {
480489 `ID{enter}={enter}${ jobID } {enter}` ,
481490 ) ;
482491 } ) ;
483- cy . get ( '[role="group"]' ) . find ( "button" ) . should ( "have.length" , 5 ) ;
484- cy . get ( '[role="group"]' ) . find ( "button" ) . contains ( "ID" ) . should ( "exist" ) ;
492+ cy . get ( '[data-testid="search-bar"]' )
493+ . find ( ".MuiChip-root" )
494+ . should ( "have.length" , 3 ) ;
495+ cy . get ( '[data-testid="search-bar"]' )
496+ . find ( ".MuiChip-root" )
497+ . contains ( "ID" )
498+ . should ( "exist" ) ;
485499
486500 // Wait for the filter to apply
487501 cy . wait ( 1000 ) ;
@@ -509,15 +523,21 @@ describe("Job Monitor", () => {
509523 // Wait for the filter to apply
510524 cy . wait ( 1000 ) ;
511525
512- cy . get ( '[role="group"]' ) . find ( "button" ) . should ( "have.length" , 5 ) ;
526+ cy . get ( '[data-testid="search-bar"]' )
527+ . find ( ".MuiChip-root" )
528+ . should ( "have.length" , 3 ) ;
513529
514530 cy . get ( ".MuiButtonBase-root" ) . contains ( "Job Monitor 2" ) . click ( ) ;
515531
516- cy . get ( '[role="group"]' ) . find ( "button" ) . should ( "have.length" , 2 ) ;
532+ cy . get ( '[data-testid="search-bar"]' )
533+ . find ( ".MuiChip-root" )
534+ . should ( "have.length" , 0 ) ;
517535
518536 cy . get ( ".MuiButtonBase-root" ) . contains ( "Job Monitor" ) . click ( ) ;
519537
520- cy . get ( '[role="group"]' ) . find ( "button" ) . should ( "have.length" , 5 ) ;
538+ cy . get ( '[data-testid="search-bar"]' )
539+ . find ( ".MuiChip-root" )
540+ . should ( "have.length" , 3 ) ;
521541 } ) ;
522542
523543 it ( "should control the in the last operator utilization" , ( ) => {
@@ -529,7 +549,9 @@ describe("Job Monitor", () => {
529549 // Wait for the filter to apply
530550 cy . wait ( 1000 ) ;
531551
532- cy . get ( '[role="group"]' ) . find ( "button" ) . should ( "have.length" , 5 ) ;
552+ cy . get ( '[data-testid="search-bar"]' )
553+ . find ( ".MuiChip-root" )
554+ . should ( "have.length" , 3 ) ;
533555
534556 cy . get ( "table" ) . should ( "be.visible" ) ;
535557 } ) ;
0 commit comments