@@ -13,19 +13,20 @@ describe('Data List Demo Test', () => {
1313 . should ( 'have.class' , 'pf-m-no-plain-on-glass' )
1414 . and ( 'have.class' , 'pf-m-plain' ) ;
1515
16- /**
17- * This test fails due to a css bug.
18- */
19- cy . get ( '[data-testid="data-list-glass-plain-both"]' ) . then ( ( $el ) => {
20- const el = $el [ 0 ] ;
21- const win = el . ownerDocument . defaultView ;
22- if ( ! win ) {
23- throw new Error ( 'expected window' ) ;
24- }
25- const bg = win . getComputedStyle ( el ) . backgroundColor ;
26- const fullyTransparent = bg === 'transparent' || bg === 'rgba(0, 0, 0, 0)' || bg === 'rgba(0,0,0,0)' ;
27- expect ( fullyTransparent , `expected non-transparent background, got ${ bg } ` ) . to . eq ( false ) ;
28- } ) ;
16+ // Glass/plain tokens set --pf-v6-c-data-list__item--BackgroundColor on the list; items paint it.
17+ // The `<ul>` has no background-color rule, so its computed background stays transparent.
18+ cy . get ( '[data-testid="data-list-glass-plain-both"] .pf-v6-c-data-list__item' )
19+ . first ( )
20+ . then ( ( $item ) => {
21+ const el = $item [ 0 ] ;
22+ const win = el . ownerDocument . defaultView ;
23+ if ( ! win ) {
24+ throw new Error ( 'expected window' ) ;
25+ }
26+ const bg = win . getComputedStyle ( el ) . backgroundColor ;
27+ const fullyTransparent = bg === 'transparent' || bg === 'rgba(0, 0, 0, 0)' || bg === 'rgba(0,0,0,0)' ;
28+ expect ( fullyTransparent , `expected non-transparent item background, got ${ bg } ` ) . to . eq ( false ) ;
29+ } ) ;
2930 } ) ;
3031
3132 it ( 'Verify rows selectable' , ( ) => {
0 commit comments