refactor: IS_DART === false

This commit is contained in:
Victor Berchet
2016-07-30 19:31:25 -07:00
parent 28c4852cd6
commit 106db0aba8
20 changed files with 106 additions and 663 deletions

View File

@ -9,7 +9,7 @@
import {AsyncTestCompleter, describe, it, iit, ddescribe, expect, inject, beforeEach,} from '@angular/core/testing/testing_internal';
import {PromiseWrapper} from '../src/facade/async';
import {Type, IS_DART} from '../src/facade/lang';
import {Type} from '../src/facade/lang';
import {RouteRegistry} from '../src/route_registry';
import {RouteConfig, Route, Redirect, AuxRoute, AsyncRoute} from '../src/route_config/route_config_decorator';
@ -256,12 +256,8 @@ export function main() {
expect(() => registry.config(RootHostCmp, new AuxRoute({path: '/', component: null})))
.toThrowError('Component for route "/" is not defined, or is not a class.');
// This would never happen in Dart
if (!IS_DART) {
expect(
() => registry.config(RootHostCmp, new Route({path: '/', component: <Type>(<any>4)})))
.toThrowError('Component for route "/" is not defined, or is not a class.');
}
expect(() => registry.config(RootHostCmp, new Route({path: '/', component: <Type>(<any>4)})))
.toThrowError('Component for route "/" is not defined, or is not a class.');
});
it('should throw when linkParams are not terminal', () => {