@@ -156,3 +156,33 @@ test(`Renders with class ${styles.modifiers.plain} when isPlain is true`, () =>
156156
157157 expect ( screen . getByRole ( 'grid' , { name : 'Test table' } ) ) . toHaveClass ( styles . modifiers . plain ) ;
158158} ) ;
159+
160+ test ( `Does not render with class ${ styles . modifiers . plain } when isPlain is not defined` , ( ) => {
161+ render ( < Table aria-label = "Test table" /> ) ;
162+
163+ expect ( screen . getByRole ( 'grid' , { name : 'Test table' } ) ) . not . toHaveClass ( styles . modifiers . plain ) ;
164+ } ) ;
165+
166+ test ( `Does not render with class ${ styles . modifiers . plain } when isPlain is false` , ( ) => {
167+ render ( < Table isPlain = { false } aria-label = "Test table" /> ) ;
168+
169+ expect ( screen . getByRole ( 'grid' , { name : 'Test table' } ) ) . not . toHaveClass ( styles . modifiers . plain ) ;
170+ } ) ;
171+
172+ test ( `Renders with class ${ styles . modifiers . noPlain } when isPlain is false` , ( ) => {
173+ render ( < Table isPlain = { false } aria-label = "Test table" /> ) ;
174+
175+ expect ( screen . getByRole ( 'grid' , { name : 'Test table' } ) ) . toHaveClass ( styles . modifiers . noPlain ) ;
176+ } ) ;
177+
178+ test ( `Does not render with class ${ styles . modifiers . noPlain } when isPlain is not defined` , ( ) => {
179+ render ( < Table aria-label = "Test table" /> ) ;
180+
181+ expect ( screen . getByRole ( 'grid' , { name : 'Test table' } ) ) . not . toHaveClass ( styles . modifiers . noPlain ) ;
182+ } ) ;
183+
184+ test ( `Does not render with class ${ styles . modifiers . noPlain } when isPlain is true` , ( ) => {
185+ render ( < Table isPlain aria-label = "Test table" /> ) ;
186+
187+ expect ( screen . getByRole ( 'grid' , { name : 'Test table' } ) ) . not . toHaveClass ( styles . modifiers . noPlain ) ;
188+ } ) ;
0 commit comments