UNPKG

declapract

Version:

A tool to declaratively define best practices, maintainable evolve them, and scalably enforce them.

17 lines 991 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); const listFilesInDirectory_1 = require("./listFilesInDirectory"); describe('listFilesInDirectory', () => { it('should find file paths', async () => { const paths = await (0, listFilesInDirectory_1.listFilesInDirectory)({ directory: __dirname }); expect(paths).toContain('listFilesInDirectory.ts'); expect(paths).toContain('listFilesInDirectory.integration.test.ts'); }); it('should find files nested in directory', async () => { const paths = await (0, listFilesInDirectory_1.listFilesInDirectory)({ directory: `${__dirname}/../` }); expect(paths).toContain('filepaths/listFilesInDirectory.ts'); expect(paths).toContain('filepaths/listFilesInDirectory.integration.test.ts'); expect(paths).not.toContain('filepaths'); // should not reference the directory itself though }); }); //# sourceMappingURL=listFilesInDirectory.integration.test.js.map