@@ -52,6 +52,8 @@ describe('Row', () => {
5252 describe ( 'material' , ( ) => {
5353
5454 const MATERIAL_UNSTRIPED_ROW_RESULT = '<div style="display:flex;flex-direction:row;flex-wrap:wrap;flex-grow:0;width:100%;color:rgba(0, 0, 0, 0.87);min-height:48px;"></div>' ;
55+
56+ const MATERIAL_STRIPED_ROW_RESULT = '<div style="display:flex;flex-direction:row;flex-wrap:wrap;flex-grow:0;width:100%;color:rgba(0, 0, 0, 0.87);background-color:rgba(127, 221, 233, 0.4);min-height:48px;"></div>' ;
5557
5658 it ( 'does not take striped boolean into account if material is false' , ( ) => {
5759 const wrapper = shallow (
@@ -71,10 +73,15 @@ describe('Row', () => {
7173 const wrapper = rowWrapper ( { material : true } ) ;
7274 expect ( wrapper . html ( ) ) . to . equal ( MATERIAL_UNSTRIPED_ROW_RESULT ) ;
7375 } ) ;
76+
77+ it ( 'considers 0 index as pair' , ( ) => {
78+ const wrapper = rowWrapper ( { material : true , index : 0 } ) ;
79+ expect ( wrapper . html ( ) ) . to . equal ( MATERIAL_STRIPED_ROW_RESULT ) ;
80+ } ) ;
7481
7582 it ( 'add correct style if index is pair and striped is true' , ( ) => {
7683 const wrapper = rowWrapper ( { index : 2 } ) ;
77- expect ( wrapper . html ( ) ) . to . equal ( '<div style="display:flex;flex-direction:row;flex-wrap:wrap;flex-grow:0;width:100%;color:rgba(0, 0, 0, 0.87);background-color:rgba(127, 221, 233, 0.4);min-height:48px;"></div>' ) ;
84+ expect ( wrapper . html ( ) ) . to . equal ( MATERIAL_STRIPED_ROW_RESULT ) ;
7885 } ) ;
7986
8087 it ( 'add correct style if index is impair and striped is true' , ( ) => {
0 commit comments