@jsenv/test 3.5.14 → 3.5.16

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.
@@ -4682,7 +4682,7 @@ const renderExecutionLabel = (execution, logOptions) => {
4682
4682
  {
4683
4683
  const infos = [];
4684
4684
  if (logOptions.group) {
4685
- infos.push(execution.group);
4685
+ infos.push(ANSI.color(execution.group, ANSI.GREY));
4686
4686
  }
4687
4687
  const { timings, memoryUsage } = execution.result;
4688
4688
  if (timings) {
@@ -5132,22 +5132,40 @@ const renderStatusRepartition = (counters, { showProgression } = {}) => {
5132
5132
  if (counters.planified === 0) {
5133
5133
  return ``;
5134
5134
  }
5135
- if (counters.skipped === counters.planified) {
5135
+ if (
5136
+ counters.skipped === counters.executed ||
5137
+ counters.skipped === counters.planified
5138
+ ) {
5136
5139
  return `all ${ANSI.color(`skipped`, COLOR_SKIPPED)}`;
5137
5140
  }
5138
- if (counters.aborted === counters.planified) {
5141
+ if (
5142
+ counters.aborted === counters.executed ||
5143
+ counters.aborted === counters.planified
5144
+ ) {
5139
5145
  return `all ${ANSI.color(`aborted`, COLOR_ABORTED)}`;
5140
5146
  }
5141
- if (counters.cancelled === counters.planified) {
5147
+ if (
5148
+ counters.cancelled === counters.executed ||
5149
+ counters.cancelled === counters.planified
5150
+ ) {
5142
5151
  return `all ${ANSI.color(`cancelled`, COLOR_CANCELLED)}`;
5143
5152
  }
5144
- if (counters.timedout === counters.planified) {
5153
+ if (
5154
+ counters.timedout === counters.executed ||
5155
+ counters.timedout === counters.planified
5156
+ ) {
5145
5157
  return `all ${ANSI.color(`timed out`, COLOR_TIMEOUT)}`;
5146
5158
  }
5147
- if (counters.failed === counters.planified) {
5159
+ if (
5160
+ counters.failed === counters.executed ||
5161
+ counters.failed === counters.planified
5162
+ ) {
5148
5163
  return `all ${ANSI.color(`failed`, COLOR_FAILED)}`;
5149
5164
  }
5150
- if (counters.completed === counters.planified) {
5165
+ if (
5166
+ counters.completed === counters.executed ||
5167
+ counters.completed === counters.planified
5168
+ ) {
5151
5169
  return `all ${ANSI.color(`completed`, COLOR_COMPLETED)}`;
5152
5170
  }
5153
5171
  const parts = [];
@@ -5605,9 +5623,8 @@ const startServerUsingCommand = async (
5605
5623
  let isAbort = false;
5606
5624
  let isTeardown = false;
5607
5625
  let processClosed = false;
5608
- let stderr = "";
5609
5626
  spawnedProcess.stderr.on("data", (data) => {
5610
- stderr += String(data);
5627
+ logger.error(data);
5611
5628
  });
5612
5629
  const closedPromise = new Promise((resolve) => {
5613
5630
  spawnedProcess.once("exit", (exitCode, signal) => {
@@ -5618,10 +5635,7 @@ const startServerUsingCommand = async (
5618
5635
  );
5619
5636
  } else {
5620
5637
  logger.error(
5621
- `web server process premature exit exitCode=${exitCode}, exitSignal=${signal}, pid=${spawnedProcess.pid}
5622
- --- stderr ---
5623
- ${stderr}
5624
- --------------`,
5638
+ `web server process premature exit exitCode=${exitCode}, exitSignal=${signal}, pid=${spawnedProcess.pid}`,
5625
5639
  );
5626
5640
  }
5627
5641
  resolve();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jsenv/test",
3
- "version": "3.5.14",
3
+ "version": "3.5.16",
4
4
  "license": "MIT",
5
5
  "repository": {
6
6
  "type": "git",
@@ -439,7 +439,7 @@ const renderExecutionLabel = (execution, logOptions) => {
439
439
  {
440
440
  const infos = [];
441
441
  if (logOptions.group) {
442
- infos.push(execution.group);
442
+ infos.push(ANSI.color(execution.group, ANSI.GREY));
443
443
  }
444
444
  const { timings, memoryUsage } = execution.result;
445
445
  if (timings) {
@@ -889,22 +889,40 @@ const renderStatusRepartition = (counters, { showProgression } = {}) => {
889
889
  if (counters.planified === 0) {
890
890
  return ``;
891
891
  }
892
- if (counters.skipped === counters.planified) {
892
+ if (
893
+ counters.skipped === counters.executed ||
894
+ counters.skipped === counters.planified
895
+ ) {
893
896
  return `all ${ANSI.color(`skipped`, COLOR_SKIPPED)}`;
894
897
  }
895
- if (counters.aborted === counters.planified) {
898
+ if (
899
+ counters.aborted === counters.executed ||
900
+ counters.aborted === counters.planified
901
+ ) {
896
902
  return `all ${ANSI.color(`aborted`, COLOR_ABORTED)}`;
897
903
  }
898
- if (counters.cancelled === counters.planified) {
904
+ if (
905
+ counters.cancelled === counters.executed ||
906
+ counters.cancelled === counters.planified
907
+ ) {
899
908
  return `all ${ANSI.color(`cancelled`, COLOR_CANCELLED)}`;
900
909
  }
901
- if (counters.timedout === counters.planified) {
910
+ if (
911
+ counters.timedout === counters.executed ||
912
+ counters.timedout === counters.planified
913
+ ) {
902
914
  return `all ${ANSI.color(`timed out`, COLOR_TIMEOUT)}`;
903
915
  }
904
- if (counters.failed === counters.planified) {
916
+ if (
917
+ counters.failed === counters.executed ||
918
+ counters.failed === counters.planified
919
+ ) {
905
920
  return `all ${ANSI.color(`failed`, COLOR_FAILED)}`;
906
921
  }
907
- if (counters.completed === counters.planified) {
922
+ if (
923
+ counters.completed === counters.executed ||
924
+ counters.completed === counters.planified
925
+ ) {
908
926
  return `all ${ANSI.color(`completed`, COLOR_COMPLETED)}`;
909
927
  }
910
928
  const parts = [];
@@ -42,9 +42,8 @@ export const startServerUsingCommand = async (
42
42
  let isAbort = false;
43
43
  let isTeardown = false;
44
44
  let processClosed = false;
45
- let stderr = "";
46
45
  spawnedProcess.stderr.on("data", (data) => {
47
- stderr += String(data);
46
+ logger.error(data);
48
47
  });
49
48
  const closedPromise = new Promise((resolve) => {
50
49
  spawnedProcess.once("exit", (exitCode, signal) => {
@@ -55,10 +54,7 @@ export const startServerUsingCommand = async (
55
54
  );
56
55
  } else {
57
56
  logger.error(
58
- `web server process premature exit exitCode=${exitCode}, exitSignal=${signal}, pid=${spawnedProcess.pid}
59
- --- stderr ---
60
- ${stderr}
61
- --------------`,
57
+ `web server process premature exit exitCode=${exitCode}, exitSignal=${signal}, pid=${spawnedProcess.pid}`,
62
58
  );
63
59
  }
64
60
  resolve();