smartstring/test/test.typescript.ts

23 lines
646 B
TypeScript
Raw Normal View History

2017-10-05 13:55:59 +00:00
import * as smartstring from '../ts/index'
import { tap, expect } from 'tapbundle'
// typscript
tap.test('expect match reference paths', async () => {
// tslint:disable-next-line:no-unused-expression
expect(
smartstring.typescript.regexReferencePath.test('/// <reference path=\"\" />')
).to.be.true
// tslint:disable-next-line:no-unused-expression
expect(
smartstring.typescript.regexReferencePath.test("/// <reference path='' />")
).to.be.true
// tslint:disable-next-line:no-unused-expression
expect(
smartstring.typescript.regexReferencePath.test('/// <referencepath=\"\" />')
).to.be.false
})
tap.start()