Skip to content

Commit

Permalink
fix(deps): abstract modifier
Browse files Browse the repository at this point in the history
fix #626
  • Loading branch information
vogloblinsky committed Aug 27, 2018
1 parent 1f539b8 commit 1e6eecb
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/app/engines/html-engine-helpers/modif-kind-helper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,9 @@ export class ModifKindHelper implements IHtmlEngineHelper {
case SyntaxKind.AsyncKeyword:
_kindText = 'Async';
break;
case SyntaxKind.AbstractKeyword:
_kindText = 'Abstract';
break;
}
return new Handlebars.SafeString(_kindText);
}
Expand Down
6 changes: 6 additions & 0 deletions test/src/cli/cli-generation-big-app.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -714,4 +714,10 @@ describe('CLI simple generation - big app', () => {
let file = read(distFolder + '/injectables/TodoStore.html');
expect(file).to.contain('Map<string, number>');
});

it('correct support of abstract and async modifiers', () => {
let file = read(distFolder + '/classes/Todo.html');
expect(file).to.contain('<span class="modifier">Abstract</span>');
expect(file).to.contain('<span class="modifier">Async</span>');
});
});
4 changes: 4 additions & 0 deletions test/src/todomvc-ng2/src/app/shared/models/todo.model.ts
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,10 @@ export class Todo extends Tada {
azert() {
return 5;
}

abstract abstractMethod(input : string) : string;

async asyncMethod() {}
}

export type PopupPosition = ElementRef | HTMLElement;

0 comments on commit 1e6eecb

Please sign in to comment.