| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent f58c5ba commit 46a0ca2
5 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -21,7 +21,7 @@ const { | |||
| 21 | 21 | const { getOptionValue } = require('internal/options'); | |
| 22 | 22 | const { FilesWatcher } = require('internal/watch_mode/files_watcher'); | |
| 23 | 23 | const { green, blue, red, white, clear } = require('internal/util/colors'); | |
| 24 | - const { convertToValidSignal } = require('internal/util'); | ||
| 24 | + const { convertToValidSignal, kEmptyObject } = require('internal/util'); | ||
| 25 | 25 | ||
| 26 | 26 | const { spawn } = require('child_process'); | |
| 27 | 27 | const { inspect } = require('util'); | |
@@ -173,11 +173,14 @@ async function stop(child) { | |||
| 173 | 173 | ||
| 174 | 174 | let restarting = false; | |
| 175 | 175 | ||
| 176 | - async function restart(child) { | ||
| 176 | + async function restart(child, trigger) { | ||
| 177 | 177 | if (restarting) return; | |
| 178 | 178 | restarting = true; | |
| 179 | 179 | try { | |
| 180 | 180 | if (!kPreserveOutput) process.stdout.write(clear); | |
| 181 | + if (trigger) { | ||
| 182 | + process.stdout.write(`${blue}Change detected in ${inspect(trigger)}${white}\n`); | ||
| 183 | + } | ||
| 181 | 184 | process.stdout.write(`${green}Restarting ${kCommandStr}${white}\n`); | |
| 182 | 185 | await stop(child); | |
| 183 | 186 | return start(); | |
@@ -188,8 +191,8 @@ async function restart(child) { | |||
| 188 | 191 | ||
| 189 | 192 | async function init() { | |
| 190 | 193 | let child = start(); | |
| 191 | - const restartChild = async () => { | ||
| 192 | - child = await restart(child); | ||
| 194 | + const restartChild = async ({ trigger } = kEmptyObject) => { | ||
| 195 | + child = await restart(child, trigger); | ||
| 193 | 196 | }; | |
| 194 | 197 | watcher | |
| 195 | 198 | .on('changed', restartChild) | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -39,6 +39,7 @@ class FilesWatcher extends EventEmitter { | |||
| 39 | 39 | #ownerDependencies = new SafeMap(); | |
| 40 | 40 | #debounceOwners = new SafeSet(); | |
| 41 | 41 | #debounceTimer; | |
| 42 | + #debounceTrigger; | ||
| 42 | 43 | #debounce; | |
| 43 | 44 | #mode; | |
| 44 | 45 | #signal; | |
@@ -98,11 +99,13 @@ class FilesWatcher extends EventEmitter { | |||
| 98 | 99 | this.#debounceOwners.add(owner); | |
| 99 | 100 | } | |
| 100 | 101 | } | |
| 102 | + this.#debounceTrigger = trigger; | ||
| 101 | 103 | clearTimeout(this.#debounceTimer); | |
| 102 | 104 | this.#debounceTimer = setTimeout(() => { | |
| 103 | 105 | this.#debounceTimer = null; | |
| 104 | - this.emit('changed', { owners: this.#debounceOwners, eventType }); | ||
| 106 | + this.emit('changed', { owners: this.#debounceOwners, eventType, trigger: this.#debounceTrigger }); | ||
| 105 | 107 | this.#debounceOwners.clear(); | |
| 108 | + this.#debounceTrigger = undefined; | ||
| 106 | 109 | }, this.#debounce).unref(); | |
| 107 | 110 | } | |
| 108 | 111 | ||
@@ -207,6 +210,7 @@ class FilesWatcher extends EventEmitter { | |||
| 207 | 210 | clearTimeout(this.#debounceTimer); | |
| 208 | 211 | this.#debounceTimer = null; | |
| 209 | 212 | this.#debounceOwners.clear(); | |
| 213 | + this.#debounceTrigger = undefined; | ||
| 210 | 214 | this.#watchers.forEach(this.#unwatch); | |
| 211 | 215 | this.#watchers.clear(); | |
| 212 | 216 | this.#filteredFiles.clear(); | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -120,6 +120,7 @@ try { | |||
| 120 | 120 | const { stderr: stderr2, stdout: stdout2 } = await failedRestart; | |
| 121 | 121 | assert.match(stderr2, /SyntaxError: Invalid or unexpected token/); | |
| 122 | 122 | assert.deepStrictEqual(stdout2, [ | |
| 123 | + `Change detected in ${inspect(file)}`, | ||
| 123 | 124 | `Restarting ${inspect(file)}`, | |
| 124 | 125 | `Failed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 125 | 126 | ]); | |
@@ -132,6 +133,7 @@ try { | |||
| 132 | 133 | // Verify it recovered and ran successfully | |
| 133 | 134 | assert.strictEqual(stderr3, ''); | |
| 134 | 135 | assert.deepStrictEqual(stdout3, [ | |
| 136 | + `Change detected in ${inspect(file)}`, | ||
| 135 | 137 | `Restarting ${inspect(file)}`, | |
| 136 | 138 | 'hello again, world', | |
| 137 | 139 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -19,6 +19,10 @@ function restart(file) { | |||
| 19 | 19 | return () => clearInterval(timer); | |
| 20 | 20 | } | |
| 21 | 21 | ||
| 22 | + function changeDetected(file) { | ||
| 23 | + return `Change detected in ${inspect(file)}`; | ||
| 24 | + } | ||
| 25 | + | ||
| 22 | 26 | let tmpFiles = 0; | |
| 23 | 27 | function createTmpFile(content = 'console.log(\'running\');', ext = '.js', basename = tmpdir.path) { | |
| 24 | 28 | const file = path.join(basename, `${tmpFiles++}${ext}`); | |
@@ -108,6 +112,7 @@ const w = new Worker(${JSON.stringify(worker)}); | |||
| 108 | 112 | assert.deepStrictEqual(stdout, [ | |
| 109 | 113 | 'worker running', | |
| 110 | 114 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 115 | + changeDetected(worker), | ||
| 111 | 116 | `Restarting ${inspect(file)}`, | |
| 112 | 117 | 'worker running', | |
| 113 | 118 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
@@ -142,6 +147,7 @@ const w = new Worker(${JSON.stringify(worker)}); | |||
| 142 | 147 | assert.deepStrictEqual(stdout, [ | |
| 143 | 148 | 'dep v1', | |
| 144 | 149 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 150 | + changeDetected(dep), | ||
| 145 | 151 | `Restarting ${inspect(file)}`, | |
| 146 | 152 | 'dep v1', | |
| 147 | 153 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
@@ -182,6 +188,7 @@ const w = new Worker(${JSON.stringify(worker)}); | |||
| 182 | 188 | assert.deepStrictEqual(stdout, [ | |
| 183 | 189 | 'sub-dep v1', | |
| 184 | 190 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 191 | + changeDetected(subDep), | ||
| 185 | 192 | `Restarting ${inspect(file)}`, | |
| 186 | 193 | 'sub-dep v1', | |
| 187 | 194 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
@@ -210,6 +217,7 @@ new Worker(new URL(${JSON.stringify(pathToFileURL(worker))})); | |||
| 210 | 217 | assert.deepStrictEqual(stdout, [ | |
| 211 | 218 | 'worker running', | |
| 212 | 219 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 220 | + changeDetected(worker), | ||
| 213 | 221 | `Restarting ${inspect(file)}`, | |
| 214 | 222 | 'worker running', | |
| 215 | 223 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
@@ -244,6 +252,7 @@ new Worker(new URL(${JSON.stringify(pathToFileURL(worker))})); | |||
| 244 | 252 | assert.deepStrictEqual(stdout, [ | |
| 245 | 253 | 'dep v1', | |
| 246 | 254 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 255 | + changeDetected(dep), | ||
| 247 | 256 | `Restarting ${inspect(file)}`, | |
| 248 | 257 | 'dep v1', | |
| 249 | 258 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
@@ -284,6 +293,7 @@ new Worker(new URL(${JSON.stringify(pathToFileURL(worker))})); | |||
| 284 | 293 | assert.deepStrictEqual(stdout, [ | |
| 285 | 294 | 'sub-dep v1', | |
| 286 | 295 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 296 | + changeDetected(subDep), | ||
| 287 | 297 | `Restarting ${inspect(file)}`, | |
| 288 | 298 | 'sub-dep v1', | |
| 289 | 299 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -23,6 +23,10 @@ function restart(file, content = readFileSync(file)) { | |||
| 23 | 23 | return () => clearInterval(timer); | |
| 24 | 24 | } | |
| 25 | 25 | ||
| 26 | + function changeDetected(file) { | ||
| 27 | + return `Change detected in ${inspect(file)}`; | ||
| 28 | + } | ||
| 29 | + | ||
| 26 | 30 | let tmpFiles = 0; | |
| 27 | 31 | function createTmpFile(content = 'console.log("running");', ext = '.js', basename = tmpdir.path) { | |
| 28 | 32 | const file = path.join(basename, `${tmpFiles++}${ext}`); | |
@@ -198,6 +202,7 @@ describe('watch mode', { concurrency: !process.env.TEST_PARALLEL, timeout: 60_00 | |||
| 198 | 202 | assert.deepStrictEqual(stdout, [ | |
| 199 | 203 | 'running', | |
| 200 | 204 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 205 | + changeDetected(file), | ||
| 201 | 206 | `Restarting ${inspect(file)}`, | |
| 202 | 207 | 'running', | |
| 203 | 208 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
@@ -212,6 +217,7 @@ describe('watch mode', { concurrency: !process.env.TEST_PARALLEL, timeout: 60_00 | |||
| 212 | 217 | assert.deepStrictEqual(stdout, [ | |
| 213 | 218 | 'running', | |
| 214 | 219 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 220 | + changeDetected(file), | ||
| 215 | 221 | `Restarting ${inspect(file)}`, | |
| 216 | 222 | 'running', | |
| 217 | 223 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
@@ -233,6 +239,7 @@ describe('watch mode', { concurrency: !process.env.TEST_PARALLEL, timeout: 60_00 | |||
| 233 | 239 | ||
| 234 | 240 | assert.strictEqual(stderr, ''); | |
| 235 | 241 | assert.deepStrictEqual(stdout, [ | |
| 242 | + changeDetected(envFile), | ||
| 236 | 243 | `Restarting ${inspect(jsFile)}`, | |
| 237 | 244 | 'ENV: value2', | |
| 238 | 245 | `Completed running ${inspect(jsFile)}. Waiting for file changes before restarting...`, | |
@@ -258,6 +265,7 @@ describe('watch mode', { concurrency: !process.env.TEST_PARALLEL, timeout: 60_00 | |||
| 258 | 265 | ||
| 259 | 266 | assert.strictEqual(stderr, ''); | |
| 260 | 267 | assert.deepStrictEqual(stdout, [ | |
| 268 | + changeDetected(envFile), | ||
| 261 | 269 | `Restarting ${inspect(jsFile)}`, | |
| 262 | 270 | 'ENV: value1', | |
| 263 | 271 | 'ENV2: newValue', | |
@@ -284,6 +292,7 @@ describe('watch mode', { concurrency: !process.env.TEST_PARALLEL, timeout: 60_00 | |||
| 284 | 292 | ||
| 285 | 293 | assert.strictEqual(stderr, ''); | |
| 286 | 294 | assert.deepStrictEqual(stdout, [ | |
| 295 | + changeDetected(envFile), | ||
| 287 | 296 | `Restarting ${inspect(jsFile)}`, | |
| 288 | 297 | 'ENV: value1', | |
| 289 | 298 | 'ENV2: newValue', | |
@@ -327,6 +336,7 @@ describe('watch mode', { concurrency: !process.env.TEST_PARALLEL, timeout: 60_00 | |||
| 327 | 336 | assert.match(stderr, /Error: fails\r?\n/); | |
| 328 | 337 | assert.deepStrictEqual(stdout, [ | |
| 329 | 338 | `Failed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 339 | + changeDetected(file), | ||
| 330 | 340 | `Restarting ${inspect(file)}`, | |
| 331 | 341 | `Failed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 332 | 342 | ]); | |
@@ -346,6 +356,7 @@ describe('watch mode', { concurrency: !process.env.TEST_PARALLEL, timeout: 60_00 | |||
| 346 | 356 | assert.deepStrictEqual(stdout, [ | |
| 347 | 357 | 'running', | |
| 348 | 358 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 359 | + changeDetected(watchedFile), | ||
| 349 | 360 | `Restarting ${inspect(file)}`, | |
| 350 | 361 | 'running', | |
| 351 | 362 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
@@ -372,6 +383,7 @@ describe('watch mode', { concurrency: !process.env.TEST_PARALLEL, timeout: 60_00 | |||
| 372 | 383 | assert.match(stderr, /Error: Cannot find module/g); | |
| 373 | 384 | assert.deepStrictEqual(stdout, [ | |
| 374 | 385 | `Failed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 386 | + changeDetected(watchedFile), | ||
| 375 | 387 | `Restarting ${inspect(file)}`, | |
| 376 | 388 | `Failed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 377 | 389 | ]); | |
@@ -396,6 +408,7 @@ describe('watch mode', { concurrency: !process.env.TEST_PARALLEL, timeout: 60_00 | |||
| 396 | 408 | assert.match(stderr, /Error: Cannot find module/g); | |
| 397 | 409 | assert.deepStrictEqual(stdout, [ | |
| 398 | 410 | `Failed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 411 | + changeDetected(watchedFile), | ||
| 399 | 412 | `Restarting ${inspect(file)}`, | |
| 400 | 413 | `Failed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 401 | 414 | ]); | |
@@ -411,6 +424,7 @@ console.log("don't show me");`); | |||
| 411 | 424 | assert.strictEqual(stderr, ''); | |
| 412 | 425 | assert.deepStrictEqual(stdout, [ | |
| 413 | 426 | 'running', | |
| 427 | + changeDetected(file), | ||
| 414 | 428 | `Restarting ${inspect(file)}`, | |
| 415 | 429 | 'running', | |
| 416 | 430 | ]); | |
@@ -428,6 +442,7 @@ console.log(dependency); | |||
| 428 | 442 | assert.deepStrictEqual(stdout, [ | |
| 429 | 443 | '{}', | |
| 430 | 444 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 445 | + changeDetected(dependency), | ||
| 431 | 446 | `Restarting ${inspect(file)}`, | |
| 432 | 447 | '{}', | |
| 433 | 448 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
@@ -446,6 +461,7 @@ console.log(dependency); | |||
| 446 | 461 | assert.deepStrictEqual(stdout, [ | |
| 447 | 462 | '{}', | |
| 448 | 463 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 464 | + changeDetected(dependency), | ||
| 449 | 465 | `Restarting ${inspect(file)}`, | |
| 450 | 466 | '{}', | |
| 451 | 467 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
@@ -460,9 +476,11 @@ console.log(dependency); | |||
| 460 | 476 | assert.deepStrictEqual(stdout, [ | |
| 461 | 477 | 'running', | |
| 462 | 478 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 479 | + changeDetected(file), | ||
| 463 | 480 | `Restarting ${inspect(file)}`, | |
| 464 | 481 | 'running', | |
| 465 | 482 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 483 | + changeDetected(file), | ||
| 466 | 484 | `Restarting ${inspect(file)}`, | |
| 467 | 485 | 'running', | |
| 468 | 486 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
@@ -483,6 +501,7 @@ console.log(values.random); | |||
| 483 | 501 | assert.deepStrictEqual(stdout, [ | |
| 484 | 502 | random, | |
| 485 | 503 | `Completed running ${inspect(`${file} --random ${random}`)}. Waiting for file changes before restarting...`, | |
| 504 | + changeDetected(file), | ||
| 486 | 505 | `Restarting ${inspect(`${file} --random ${random}`)}`, | |
| 487 | 506 | random, | |
| 488 | 507 | `Completed running ${inspect(`${file} --random ${random}`)}. Waiting for file changes before restarting...`, | |
@@ -500,6 +519,7 @@ console.log(values.random); | |||
| 500 | 519 | assert.deepStrictEqual(stdout, [ | |
| 501 | 520 | 'running', | |
| 502 | 521 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 522 | + changeDetected(file), | ||
| 503 | 523 | `Restarting ${inspect(file)}`, | |
| 504 | 524 | 'running', | |
| 505 | 525 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
@@ -520,6 +540,7 @@ console.log(values.random); | |||
| 520 | 540 | assert.deepStrictEqual(stdout, [ | |
| 521 | 541 | 'running', | |
| 522 | 542 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 543 | + changeDetected(file), | ||
| 523 | 544 | `Restarting ${inspect(file)}`, | |
| 524 | 545 | 'running', | |
| 525 | 546 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
@@ -569,6 +590,7 @@ console.log(values.random); | |||
| 569 | 590 | assert.deepStrictEqual(stdout, [ | |
| 570 | 591 | 'running', | |
| 571 | 592 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 593 | + changeDetected(file), | ||
| 572 | 594 | `Restarting ${inspect(file)}`, | |
| 573 | 595 | 'running', | |
| 574 | 596 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
@@ -584,6 +606,7 @@ console.log(values.random); | |||
| 584 | 606 | assert.deepStrictEqual(stdout, [ | |
| 585 | 607 | 'running', | |
| 586 | 608 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 609 | + changeDetected(file), | ||
| 587 | 610 | `Restarting ${inspect(file)}`, | |
| 588 | 611 | 'running', | |
| 589 | 612 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
@@ -615,6 +638,7 @@ console.log(values.random); | |||
| 615 | 638 | 'hello', | |
| 616 | 639 | 'running', | |
| 617 | 640 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 641 | + changeDetected(watchedFile), | ||
| 618 | 642 | `Restarting ${inspect(file)}`, | |
| 619 | 643 | 'hello', | |
| 620 | 644 | 'running', | |
@@ -647,6 +671,7 @@ console.log(values.random); | |||
| 647 | 671 | 'hello', | |
| 648 | 672 | 'running', | |
| 649 | 673 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 674 | + changeDetected(watchedFile), | ||
| 650 | 675 | `Restarting ${inspect(file)}`, | |
| 651 | 676 | 'hello', | |
| 652 | 677 | 'running', | |
@@ -679,6 +704,7 @@ console.log(values.random); | |||
| 679 | 704 | 'hello', | |
| 680 | 705 | 'running', | |
| 681 | 706 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 707 | + changeDetected(watchedFile), | ||
| 682 | 708 | `Restarting ${inspect(file)}`, | |
| 683 | 709 | 'hello', | |
| 684 | 710 | 'running', | |
@@ -711,6 +737,7 @@ console.log(values.random); | |||
| 711 | 737 | 'hello', | |
| 712 | 738 | 'running', | |
| 713 | 739 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 740 | + changeDetected(watchedFile), | ||
| 714 | 741 | `Restarting ${inspect(file)}`, | |
| 715 | 742 | 'hello', | |
| 716 | 743 | 'running', | |
@@ -727,6 +754,7 @@ console.log(values.random); | |||
| 727 | 754 | assert.deepStrictEqual(stdout, [ | |
| 728 | 755 | 'running', | |
| 729 | 756 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 757 | + changeDetected(file), | ||
| 730 | 758 | `Restarting ${inspect(file)}`, | |
| 731 | 759 | 'running', | |
| 732 | 760 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
@@ -752,6 +780,7 @@ console.log(values.random); | |||
| 752 | 780 | 'hello', | |
| 753 | 781 | 'running', | |
| 754 | 782 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 783 | + changeDetected(file), | ||
| 755 | 784 | `Restarting ${inspect(file)}`, | |
| 756 | 785 | 'hello', | |
| 757 | 786 | 'running', | |
@@ -832,6 +861,7 @@ process.on('message', (message) => { | |||
| 832 | 861 | assert.deepStrictEqual(lines, [ | |
| 833 | 862 | 'running', | |
| 834 | 863 | 'Received: first message', | |
| 864 | + changeDetected(file), | ||
| 835 | 865 | `Restarting ${inspect(file)}`, | |
| 836 | 866 | 'running', | |
| 837 | 867 | 'Received: second message', | |
@@ -852,6 +882,7 @@ process.on('message', (message) => { | |||
| 852 | 882 | assert.deepStrictEqual(stdout, [ | |
| 853 | 883 | 'running', | |
| 854 | 884 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 885 | + changeDetected(file), | ||
| 855 | 886 | `Restarting ${inspect(file)}`, | |
| 856 | 887 | 'running', | |
| 857 | 888 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
@@ -874,6 +905,7 @@ process.on('message', (message) => { | |||
| 874 | 905 | assert.deepStrictEqual(stdout, [ | |
| 875 | 906 | 'running', | |
| 876 | 907 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 908 | + changeDetected(watchedFile), | ||
| 877 | 909 | `Restarting ${inspect(file)}`, | |
| 878 | 910 | 'running', | |
| 879 | 911 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
@@ -902,6 +934,7 @@ process.on('message', (message) => { | |||
| 902 | 934 | assert.deepStrictEqual(stdout, [ | |
| 903 | 935 | 'running', | |
| 904 | 936 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| 937 | + changeDetected(file), | ||
| 905 | 938 | `Restarting ${inspect(file)}`, | |
| 906 | 939 | 'running', | |
| 907 | 940 | `Completed running ${inspect(file)}. Waiting for file changes before restarting...`, | |
| Back | FazBrowse Home | New Git URL |
0 commit comments