import { expect } from 'chai'; import { DirectiveParser } from '../src/parsers/directive.parser'; describe('DirectiveParser', () => { const templateFilename: string = 'test.template.html'; const componentFilename: string = 'test.component.ts'; let parser: DirectiveParser; beforeEach(() => { parser = new DirectiveParser(); }); it('should extract contents when no translate attribute value is provided', () => { const contents = '
Hi there
Lorem Ipsum
Hello World
' }) export class TestComponent { } `; const messages = parser.process(componentFilename, contents); expect(messages).to.deep.equal(['Hello World']); }); });