UNPKG

880 BPlain TextView Raw
1import {IFileFactory, RootFileFactory} from "../src/classLibrary/RootFileFactory";
2import * as path from 'path';
3import {should} from 'chai';
4import {Core, Kore} from "@kirinnee/core";
5
6should();
7let core: Core = new Kore();
8core.ExtendPrimitives();
9
10let from = '../target/InlineFlagResolver/testDir/';
11let to = '../target/InlineFlagResolver/newDir/';
12let fileFactory: IFileFactory = new RootFileFactory(core, __dirname, from, to);
13
14describe("RootFileFactory", () => {
15 describe("FromRoot", () => {
16 it("should return the absolute path to the from folder", () => {
17 let expected = path.resolve(__dirname, from);
18 fileFactory.FromRoot.should.equal(expected);
19 });
20 });
21 describe("ToRoot", () => {
22 it("should return the absolute path tot the to folder", () => {
23 let expected = path.resolve(__dirname, to);
24 fileFactory.ToRoot.should.equal(expected);
25
26 });
27 });
28});