chore(build): Upgrade to TypeScript@1.5.3

This change also makes us compliant with 1.6.0-dev compiler,
so we can do some experiments with apps that use 1.6 features
and compile against Angular.

We should probably add a travis build for 1.6 so we stay compatible
with both versions.
This commit is contained in:
Alex Eagle
2015-07-29 20:09:54 -07:00
parent c5cb7009ca
commit 3c58878b19
28 changed files with 140 additions and 145 deletions
@@ -117,7 +117,7 @@ export function main() {
});
}
@proxy
@proxy()
@IMPLEMENTS(ChangeDetectorRef)
class SpyChangeDetectorRef extends SpyObject {
constructor() { super(ChangeDetectorRef); }
@@ -119,7 +119,7 @@ export function main() {
});
}
@proxy
@proxy()
@IMPLEMENTS(ChangeDetectorRef)
class SpyChangeDetectorRef extends SpyObject {
constructor() { super(ChangeDetectorRef); }
@@ -658,14 +658,14 @@ class DirectiveWithAttributes {
constructor(@Attribute('someAttr') someAttr: String) {}
}
@proxy
@proxy()
@IMPLEMENTS(RenderCompiler)
class SpyRenderCompiler extends SpyObject {
constructor() { super(RenderCompiler); }
noSuchMethod(m) { return super.noSuchMethod(m) }
}
@proxy
@proxy()
@IMPLEMENTS(DirectiveResolver)
class SpyDirectiveResolver extends SpyObject {
constructor() { super(DirectiveResolver); }
@@ -719,4 +719,4 @@ function collectEmbeddedPvs(pv: AppProtoView, target: AppProtoView[] = null): Ap
}
});
return target;
}
}
@@ -48,7 +48,7 @@ import {ElementRef} from 'angular2/src/core/compiler/element_ref';
import {DynamicChangeDetector, ChangeDetectorRef, Parser, Lexer} from 'angular2/src/change_detection/change_detection';
import {QueryList} from 'angular2/src/core/compiler/query_list';
@proxy
@proxy()
@IMPLEMENTS(AppView)
class DummyView extends SpyObject {
changeDetector;
@@ -59,7 +59,7 @@ class DummyView extends SpyObject {
noSuchMethod(m) { return super.noSuchMethod(m); }
}
@proxy
@proxy()
@IMPLEMENTS(ElementRef)
class DummyElementRef extends SpyObject {
boundElementIndex: number = 0;
@@ -227,7 +227,7 @@ class ThrowingComponent2 {
}
}
@proxy
@proxy()
class PropModel implements Map {
final String foo = 'foo-prop';
@@ -199,7 +199,7 @@ function createRenderViewportElementBinder(nestedProtoView) {
return new renderApi.ElementBinder({nestedProtoView: nestedProtoView});
}
@proxy
@proxy()
@IMPLEMENTS(ChangeDetection)
class ChangeDetectionSpy extends SpyObject {
constructor() { super(ChangeDetection); }
@@ -62,7 +62,7 @@ export function main() {
});
}
@proxy
@proxy()
@IMPLEMENTS(AppView)
class AppViewSpy extends SpyObject {
viewContainers: AppViewContainer[] = [null];
@@ -70,7 +70,7 @@ class AppViewSpy extends SpyObject {
noSuchMethod(m) { return super.noSuchMethod(m) }
}
@proxy
@proxy()
@IMPLEMENTS(AppViewManager)
class AppViewManagerSpy extends SpyObject {
constructor() { super(AppViewManager); }
@@ -507,21 +507,21 @@ export function main() {
});
}
@proxy
@proxy()
@IMPLEMENTS(Renderer)
class SpyRenderer extends SpyObject {
constructor() { super(Renderer); }
noSuchMethod(m) { return super.noSuchMethod(m) }
}
@proxy
@proxy()
@IMPLEMENTS(AppViewPool)
class SpyAppViewPool extends SpyObject {
constructor() { super(AppViewPool); }
noSuchMethod(m) { return super.noSuchMethod(m) }
}
@proxy
@proxy()
@IMPLEMENTS(AppViewListener)
class SpyAppViewListener extends SpyObject {
constructor() { super(AppViewListener); }
@@ -353,7 +353,7 @@ export function createEmbeddedPv(binders: ElementBinder[] = null) {
class SomeComponent {
}
@proxy
@proxy()
@IMPLEMENTS(ProtoElementInjector)
class SpyProtoElementInjector extends SpyObject {
index: number;
@@ -361,21 +361,21 @@ class SpyProtoElementInjector extends SpyObject {
noSuchMethod(m) { return super.noSuchMethod(m) }
}
@proxy
@proxy()
@IMPLEMENTS(ElementInjector)
class SpyElementInjector extends SpyObject {
constructor(public parent: ElementInjector) { super(ElementInjector); }
noSuchMethod(m) { return super.noSuchMethod(m) }
}
@proxy
@proxy()
@IMPLEMENTS(PreBuiltObjects)
class SpyPreBuiltObjects extends SpyObject {
constructor() { super(PreBuiltObjects); }
noSuchMethod(m) { return super.noSuchMethod(m) }
}
@proxy
@proxy()
@IMPLEMENTS(Injector)
class SpyInjector extends SpyObject {
constructor() { super(Injector); }
@@ -79,7 +79,7 @@ class TestComponent {
}
@proxy
@proxy()
@IMPLEMENTS(Location)
class DummyLocation extends SpyObject {
noSuchMethod(m) { return super.noSuchMethod(m) }
@@ -92,7 +92,7 @@ function makeDummyLocation() {
}
@proxy
@proxy()
@IMPLEMENTS(Router)
class DummyRouter extends SpyObject {
noSuchMethod(m) { return super.noSuchMethod(m) }
+1 -1
View File
@@ -161,7 +161,7 @@ export function main() {
});
}
@proxy
@proxy()
@IMPLEMENTS(RouterOutlet)
class DummyOutlet extends SpyObject {
noSuchMethod(m) { return super.noSuchMethod(m) }
+2 -2
View File
@@ -58,7 +58,7 @@ export function main() {
});
}
@proxy
@proxy()
@IMPLEMENTS(ElementRef)
class SpyElementRef extends SpyObject {
nativeElement;
@@ -66,7 +66,7 @@ class SpyElementRef extends SpyObject {
noSuchMethod(m) { return super.noSuchMethod(m) }
}
@proxy
@proxy()
@IMPLEMENTS(DomAdapter)
class SpyDomAdapter extends SpyObject {
constructor() { super(DomAdapter); }
@@ -21,7 +21,7 @@ class TestObj {
someComplexFunc(a) { return a; }
}
@proxy
@proxy()
@IMPLEMENTS(TestObj)
class SpyTestObj extends SpyObject {
constructor() { super(TestObj); }
@@ -69,8 +69,8 @@ export function main() {
var i0, i1;
var MyClass =
(<any>TestDecorator('test-works'))
.Class({
extends: Class({
.Class(<any>{
extends: Class(<any>{
constructor: function() {},
extendWorks: function() { return 'extend ' + this.arg; }
}),
@@ -121,7 +121,7 @@ export function main() {
});
it('should ensure that only Function|Arrays are supported', () => {
expect(() => { Class({constructor: function() {}, method: 'non_function'}); })
expect(() => { Class(<any>{constructor: function() {}, method: 'non_function'}); })
.toThrowError(
"Only Function or Array is supported in Class definition for key 'method' is 'non_function'");
});