fix(navBar): only add default animation if there is no custom animation

Closes #1671
This commit is contained in:
Andrew
2014-07-07 11:40:21 -06:00
parent 22a81fe82c
commit cdba48f196
2 changed files with 23 additions and 4 deletions

View File

@@ -323,6 +323,12 @@ describe('ionNavBar', function() {
var el = setup();
expect(el.hasClass('nav-title-slide-ios7')).toBe(true);
});
it('should not add transition if animation attribute is defined', function() {
var el = setup('animation="123abc"');
expect(el.hasClass('123abc')).toBe(true);
expect(el.hasClass('nav-title-slide-ios7')).toBe(false);
});
});
describe('Android', function() {
@@ -346,6 +352,12 @@ describe('ionNavBar', function() {
// Nav bar titles don't animation by default on Android
expect(el.hasClass('no-animation')).toBe(true);
});
it('should not add transition if animation attribute is defined', function() {
var el = setup('animation="123abc"');
expect(el.hasClass('123abc')).toBe(true);
expect(el.hasClass('no-animation')).toBe(false);
});
});
});
});