qunitx-cli 0.9.8 → 0.9.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli.js +7 -3
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -1464,11 +1464,15 @@ async function run(config) {
|
|
|
1464
1464
|
}
|
|
1465
1465
|
}
|
|
1466
1466
|
async function buildCachedContent(config, htmlPaths) {
|
|
1467
|
-
const htmlBuffers = await Promise.all(
|
|
1467
|
+
const htmlBuffers = await Promise.all(
|
|
1468
|
+
config.htmlPaths.map((htmlPath) => fs11.readFile(htmlPath).catch(() => null))
|
|
1469
|
+
);
|
|
1468
1470
|
const cachedContent = htmlPaths.reduce(
|
|
1469
1471
|
(result, _htmlPath, index) => {
|
|
1472
|
+
const buffer = htmlBuffers[index];
|
|
1473
|
+
if (buffer === null) return result;
|
|
1470
1474
|
const filePath = config.htmlPaths[index];
|
|
1471
|
-
const html =
|
|
1475
|
+
const html = buffer.toString();
|
|
1472
1476
|
if (html.includes("{{content}}")) {
|
|
1473
1477
|
result.dynamicContentHTMLs[filePath] = html;
|
|
1474
1478
|
result.htmlPathsToRunTests.push(filePath.replace(config.projectRoot, ""));
|
|
@@ -1562,7 +1566,7 @@ init_color();
|
|
|
1562
1566
|
var package_default = {
|
|
1563
1567
|
name: "qunitx-cli",
|
|
1564
1568
|
type: "module",
|
|
1565
|
-
version: "0.9.
|
|
1569
|
+
version: "0.9.10",
|
|
1566
1570
|
description: "Browser runner for QUnitx: run your qunitx tests in google-chrome",
|
|
1567
1571
|
author: "Izel Nakri",
|
|
1568
1572
|
license: "MIT",
|