feat(core): added support for detecting lifecycle events based on interfaces

This commit is contained in:
vsavkin
2015-05-27 08:08:14 -07:00
parent 2b6a653050
commit 30b6542fc8
12 changed files with 257 additions and 60 deletions
@@ -42,8 +42,7 @@ class TestObj {
class Interface {}
class ClassImplementingInterface implements Interface {
}
class ClassImplementingInterface implements Interface {}
export function main() {
describe('Reflector', () => {
@@ -85,6 +84,11 @@ export function main() {
reflector.registerType(TestObj, {"parameters": [1, 2]});
expect(reflector.parameters(TestObj)).toEqual([1, 2]);
});
it("should return an empty list when no paramters field in the stored type info", () => {
reflector.registerType(TestObj, {});
expect(reflector.parameters(TestObj)).toEqual([]);
});
});
describe("annotations", () => {