feat(tests): support custom test to run
This commit is contained in:
parent
a4f90519d3
commit
0e79ce42ca
@ -10,7 +10,7 @@ const tempDir = jetpack.cwd("temp");
|
||||
const entryFilePath = tempDir.path("testsInit.js");
|
||||
|
||||
const testsImports = testsDir
|
||||
.find({ matching: "*.test.js" })
|
||||
.find({ matching: process.env.TEST ? `${process.env.TEST}.test.js` : "*.test.js" })
|
||||
.reduce((fileContent, path) => {
|
||||
const normalizedPath = path.replace(/\\/g, "/");
|
||||
return `${fileContent}require("../tests/${normalizedPath}");\n`;
|
||||
|
Loading…
Reference in New Issue
Block a user