diff --git a/test/stateDirectivesSpec.js b/test/stateDirectivesSpec.js index 91861be16..b46ff4792 100644 --- a/test/stateDirectivesSpec.js +++ b/test/stateDirectivesSpec.js @@ -654,6 +654,17 @@ describe('uiSrefActive', function() { expect(angular.element(template[0].querySelector('a')).attr('class')).toBe('active'); })); + it('should allow multiple classes to be supplied', inject(function($rootScope, $q, $compile, $state) { + template = $compile('
Contacts
')($rootScope); + $rootScope.$digest(); + var a = angular.element(template[0].getElementsByTagName('a')[0]); + + $state.transitionTo('contacts.item.edit', { id: 1 }); + $q.flush(); + timeoutFlush(); + expect(a.attr('class')).toMatch(/active also-active/); + })); + describe('ng-{class,style} interface', function() { it('should match on abstract states that are included by the current state', inject(function($rootScope, $compile, $state, $q) { el = $compile('
Roles
')($rootScope);