Add animation
[MAILPOET-3088]
This commit is contained in:
@ -20,6 +20,10 @@ const data = {
|
||||
all: '1',
|
||||
},
|
||||
},
|
||||
fixed_bar: {
|
||||
animation: 'slideright',
|
||||
},
|
||||
popup: {},
|
||||
},
|
||||
},
|
||||
styles: 'styles definition',
|
||||
@ -138,5 +142,11 @@ describe('Form Data Load Mapper', () => {
|
||||
expect(map(mapData).settings.formPlacement.slideIn).to.have.property('styles').that.deep.eq({ width: { unit: 'percent', value: 104 } });
|
||||
expect(map(mapData).settings.formPlacement.others).to.have.property('styles').that.deep.eq({ width: { unit: 'percent', value: 105 } });
|
||||
});
|
||||
|
||||
it('Maps animation', () => {
|
||||
expect(map(data).settings.formPlacement.fixedBar).to.have.property('animation').that.eq('slideright');
|
||||
expect(map(data).settings.formPlacement.popup).to.have.property('animation').that.eq('slideup');// default
|
||||
expect(map(data).settings.formPlacement.belowPosts).to.not.have.property('animation');
|
||||
});
|
||||
});
|
||||
});
|
||||
|
@ -20,6 +20,10 @@ const data = {
|
||||
all: true,
|
||||
},
|
||||
},
|
||||
fixedBar: {
|
||||
animation: 'slideright',
|
||||
},
|
||||
popup: {},
|
||||
},
|
||||
},
|
||||
styles: 'styles definition',
|
||||
@ -80,5 +84,11 @@ describe('Form Data Save Mapper', () => {
|
||||
.that.is.an('object')
|
||||
.that.have.property('all', '1');
|
||||
});
|
||||
|
||||
it('Maps animation', () => {
|
||||
expect(map(data).settings.form_placement.fixed_bar).to.have.property('animation').that.eq('slideright');
|
||||
expect(map(data).settings.form_placement.popup).to.have.property('animation');
|
||||
expect(map(data).settings.form_placement.below_posts).to.not.have.property('animation');
|
||||
});
|
||||
});
|
||||
});
|
||||
|
Reference in New Issue
Block a user