MCPcopy
hub / github.com/subquery/subql / createTestProject

Function createTestProject

packages/cli/src/createProject.fixtures.ts:85–97  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

83}
84
85export async function createTestProject(): Promise<string> {
86 const tmpdir = await fs.promises.mkdtemp(`${os.tmpdir()}${path.sep}`);
87 const projectDir = path.join(tmpdir, projectSpecV1_0_0.name);
88
89 const exampleProject = await getExampleProject('polkadot', 'polkadot');
90
91 const projectPath = await cloneProjectTemplate(tmpdir, projectSpecV1_0_0.name, exampleProject);
92 await prepare(projectPath, projectSpecV1_0_0);
93
94 await installAndBuild(projectDir);
95
96 return projectDir;
97}
98
99export async function createMultiChainTestProject(): Promise<{multichainManifestPath: string; fullPaths: string[]}> {
100 const tmpdir = await fs.promises.mkdtemp(`${os.tmpdir()}${path.sep}`);

Callers 2

publish.test.tsFile · 0.90

Calls 4

cloneProjectTemplateFunction · 0.90
prepareFunction · 0.90
getExampleProjectFunction · 0.85
installAndBuildFunction · 0.85

Tested by

no test coverage detected