testeranto 0.79.61 → 0.79.62
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/common/Puppeteer.js
CHANGED
|
@@ -5,6 +5,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
const readline_1 = __importDefault(require("readline"));
|
|
7
7
|
const fs_1 = __importDefault(require("fs"));
|
|
8
|
+
const recursive_watch_1 = __importDefault(require("recursive-watch"));
|
|
8
9
|
const main_js_1 = require("./PM/main.js");
|
|
9
10
|
const utils_js_1 = require("./utils.js");
|
|
10
11
|
var mode = process.argv[2] === "-dev" ? "DEV" : "PROD";
|
|
@@ -73,9 +74,7 @@ exports.default = async (partialConfig) => {
|
|
|
73
74
|
}
|
|
74
75
|
});
|
|
75
76
|
console.log("ready and watching for changes...", config.buildDir);
|
|
76
|
-
|
|
77
|
-
recursive: true,
|
|
78
|
-
}, (eventType, changedFile) => {
|
|
77
|
+
(0, recursive_watch_1.default)(config.buildDir, (eventType, changedFile) => {
|
|
79
78
|
if (changedFile) {
|
|
80
79
|
config.tests.forEach(([test, runtime, tr, sidecars]) => {
|
|
81
80
|
if (eventType === "change" || eventType === "rename") {
|
|
@@ -101,4 +100,45 @@ exports.default = async (partialConfig) => {
|
|
|
101
100
|
});
|
|
102
101
|
}
|
|
103
102
|
});
|
|
103
|
+
// does not work on linux
|
|
104
|
+
// fs.watch(
|
|
105
|
+
// config.buildDir,
|
|
106
|
+
// {
|
|
107
|
+
// recursive: true,
|
|
108
|
+
// },
|
|
109
|
+
// (eventType, changedFile) => {
|
|
110
|
+
// if (changedFile) {
|
|
111
|
+
// config.tests.forEach(([test, runtime, tr, sidecars]) => {
|
|
112
|
+
// if (eventType === "change" || eventType === "rename") {
|
|
113
|
+
// if (
|
|
114
|
+
// changedFile ===
|
|
115
|
+
// test
|
|
116
|
+
// .replace("./", "node/")
|
|
117
|
+
// .split(".")
|
|
118
|
+
// .slice(0, -1)
|
|
119
|
+
// .concat("mjs")
|
|
120
|
+
// .join(".")
|
|
121
|
+
// ) {
|
|
122
|
+
// pm.launchNode(test, destinationOfRuntime(test, "node", config));
|
|
123
|
+
// }
|
|
124
|
+
// if (
|
|
125
|
+
// changedFile ===
|
|
126
|
+
// test
|
|
127
|
+
// .replace("./", "web/")
|
|
128
|
+
// .split(".")
|
|
129
|
+
// .slice(0, -1)
|
|
130
|
+
// .concat("mjs")
|
|
131
|
+
// .join(".")
|
|
132
|
+
// ) {
|
|
133
|
+
// pm.launchWeb(
|
|
134
|
+
// test,
|
|
135
|
+
// destinationOfRuntime(test, "web", config),
|
|
136
|
+
// sidecars
|
|
137
|
+
// );
|
|
138
|
+
// }
|
|
139
|
+
// }
|
|
140
|
+
// });
|
|
141
|
+
// }
|
|
142
|
+
// }
|
|
143
|
+
// );
|
|
104
144
|
};
|