describe('Ionic View Switcher', function() { var ionicViewSwitcher; beforeEach(module('ionic')); beforeEach(inject(function($ionicConfig){ $ionicConfig.views.transition('platform'); })); it('should get fallback transition', inject(function($ionicViewSwitcher) { var d = $ionicViewSwitcher.getTransitionData(); expect(d.transition).toEqual('ios'); })); it('should get transition from $ionicConfig.views.transition()', inject(function($ionicViewSwitcher, $ionicConfig) { $ionicConfig.views.transition('mambo-5'); var d = $ionicViewSwitcher.getTransitionData(); expect(d.transition).toEqual('mambo-5'); })); it('should get transition from $state', inject(function($ionicViewSwitcher) { var viewLocals = { $$state: { self: { viewTransition: 'who-let-the-dogs-out' } } }; var d = $ionicViewSwitcher.getTransitionData(viewLocals); expect(d.transition).toEqual('who-let-the-dogs-out'); })); it('should get transition from entering element attribute', inject(function($ionicViewSwitcher) { var enteringEle = angular.element('