test: 💍 测试的时候直接引用 src 导出的 solutions.rax 就行了,不用再从子目录里引了

This commit is contained in:
牧毅 2020-08-19 17:25:16 +08:00
parent 27f0e13010
commit 475534f51f

View File

@ -7,8 +7,8 @@ import path from 'path';
import chalk from 'chalk';
import CodeGenerator from '../src';
import createRaxAppBuilder from '../src/solutions/rax-app';
import { IProjectSchema } from '../src/types/schema';
import type { IProjectSchema } from '../src/types/schema';
const TEST_CASES_DIR = path.join(__dirname, '../test-cases/rax-app');
@ -42,7 +42,7 @@ function defineTest(caseDirName: string) {
}
async function exportProject(schemaJson: IProjectSchema, targetPath: string, projectName: string) {
const raxAppBuilder = createRaxAppBuilder();
const raxAppBuilder = CodeGenerator.solutions.rax();
const result = await raxAppBuilder.generateProject(schemaJson);
const publisher = CodeGenerator.publishers.disk();
await publisher.publish({