UNPKG

timpla

Version:

An optimal website development experience for [server-side] web frameworks.

19 lines (15 loc) 536 B
jest.unmock('chalk') import { pathToUrl } from '../../gulpfile.ts/lib/utils' describe('lib', () => { describe('pathToUrl', () => { it('should return a path for one argument', () => { expect(pathToUrl('hello')).toEqual('hello') }) it('should return a path for multiple arguments', () => { expect(pathToUrl('hello', 'hello')).toEqual('hello/hello') }) it('should replace forward slashes with backslashes', () => { expect(pathToUrl('hello\\me', 'hello')).toEqual('hello/me/hello') }) }) })