@@ -643,12 +643,25 @@ describe('Menu', () => {
643643 } ) ;
644644
645645 describe ( 'motion' , ( ) => {
646- it ( 'defaultMotion should work correctly' , ( ) => {
646+ it ( 'defaultMotions should work correctly' , ( ) => {
647+ const defaultMotions = {
648+ inline : { motionName : 'inlineMotion' } ,
649+ horizontal : { motionName : 'horizontalMotion' } ,
650+ other : { motionName : 'defaultMotion' } ,
651+ } ;
647652 const wrapper = mount (
648- < Menu mode = "inline" defaultMotion = { { motionName : 'defaultMotion1' } } /> ,
653+ < Menu mode = "inline" defaultMotions = { defaultMotions } /> ,
649654 ) ;
650- expect ( getMotion ( wrapper . props ( ) , wrapper . state ( ) ) ) . toEqual ( {
651- motionName : 'defaultMotion1' ,
655+ expect ( getMotion ( wrapper . props ( ) , wrapper . state ( ) , 'inline' ) ) . toEqual ( {
656+ motionName : 'inlineMotion' ,
657+ } ) ;
658+ expect ( getMotion ( wrapper . props ( ) , wrapper . state ( ) , 'horizontal' ) ) . toEqual (
659+ {
660+ motionName : 'horizontalMotion' ,
661+ } ,
662+ ) ;
663+ expect ( getMotion ( wrapper . props ( ) , wrapper . state ( ) , 'vertical' ) ) . toEqual ( {
664+ motionName : 'defaultMotion' ,
652665 } ) ;
653666 } ) ;
654667
0 commit comments