UNPKG

boats

Version:

Beautiful Open / Async Template System - Write less yaml with BOATS and Nunjucks.

16 lines (15 loc) 615 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); const tslib_1 = require("tslib"); const Injector_1 = tslib_1.__importDefault(require("../Injector")); const path_1 = tslib_1.__importDefault(require("path")); it('should ', async () => { const index = ` /ms-auth/cache-connection: $ref: ./ms-auth/cache-connection.yml /ms-auth/cache-user: $ref: ./ms-auth/cache-user.yml `; Injector_1.default.mapChannelIndex(index, path_1.default.join(process.cwd(), 'test-build/srcASYNC2/channels/index.yml')); expect(Object.keys(Injector_1.default.fileToRouteMap).length).toEqual(2); });