Skip to content

Commit 9a49d94

Browse files
test(uiView): don't test weird view setups on ng 1.0.8
1 parent 459e938 commit 9a49d94

File tree

1 file changed

+8
-7
lines changed

1 file changed

+8
-7
lines changed

test/viewDirectiveSpec.js

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -723,13 +723,14 @@ describe("UiView", function() {
723723
.state('main', { abstract: true, views: { main: {} } })
724724
.state('main.home', { views: { content: { template: 'home.html' } } });
725725
}));
726+
if (angular.version.minor >= 2) {
727+
it("shouldn't puke on weird view setups", inject(function ($compile, $rootScope, $q, $state) {
728+
$compile('<div ui-view="main"><div ui-view="content"></div></div>')($rootScope);
726729

727-
it("shouldn't puke on weird view setups", inject(function($compile, $rootScope, $q, $state) {
728-
$compile('<div ui-view="main"><div ui-view="content"></div></div>')($rootScope);
729-
730-
$state.go('main.home');
731-
$q.flush();
730+
$state.go('main.home');
731+
$q.flush();
732732

733-
expect($state.current.name).toBe('main.home');
734-
}));
733+
expect($state.current.name).toBe('main.home');
734+
}));
735+
}
735736
});

0 commit comments

Comments
 (0)