sumlyzer 0.5.0 → 0.5.1

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.
Files changed (2) hide show
  1. package/README.md +19 -39
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -11,9 +11,14 @@
11
11
  <a href="./LICENSE"><img src="https://img.shields.io/npm/l/sumlyzer.svg" alt="license" /></a>
12
12
  </p>
13
13
 
14
- Run every npm workspace's test script, one by one or in concurrence. Passing workspaces output
15
- to a single line; failing ones print only the relevant failure detail.
16
- Ends with an aggregated pass/fail summary table, so nothing scrolls out of the terminal.
14
+ `npm run test --workspaces --if-present` runs every workspace, but gives you no
15
+ aggregated summary and no way to fail fast — an early failure just scrolls off
16
+ screen once later workspaces print their own output.
17
+
18
+ Sumlyzer runs each workspace's test script, one by one or concurrently.
19
+ Passing workspaces collapse to a single line, failing ones print just the
20
+ relevant failure detail, and everything ends with an aggregated pass/fail
21
+ summary table so nothing scrolls out of the terminal.
17
22
 
18
23
  ## Requirements
19
24
 
@@ -68,6 +73,11 @@ The exit code is `1` even if every workspace's tests passed.
68
73
  - Concurrent runs (`--concurrency <n>`): run several workspaces' test scripts
69
74
  at once instead of one by one
70
75
 
76
+ ## Roadmap
77
+
78
+ - **Watch mode**: walking the workspace dependency graph (topological sort) so a change in
79
+ one workspace also re-runs the workspaces that depend on it.
80
+
71
81
  ## Example
72
82
 
73
83
  ```
@@ -77,26 +87,10 @@ running scanner
77
87
  ✓ scanner 10.1s (161/162 tests)
78
88
  running tarball
79
89
  ✓ tarball 1.8s (77/77 tests)
80
- running mama
81
- ✓ mama 1.2s (85/85 tests)
82
90
  running tree-walker
83
91
  ✓ tree-walker 3.0s (26/26 tests)
84
- running conformance
85
- ✓ conformance 1.1s (35/35 tests)
86
- running i18n
87
- ✓ i18n 1.1s (19/19 tests)
88
- running rc
89
- ✓ rc 4.1s (28/28 tests)
90
- running utils
91
- ✓ utils 1.1s (30/30 tests)
92
92
  running flags
93
93
  ✓ flags 1.1s (9/9 tests)
94
- running fs-walk
95
- ✓ fs-walk 1.1s (3/3 tests)
96
- running github
97
- ✓ github 2.9s (8/8 tests)
98
- running gitlab
99
- ✓ gitlab 4.3s (8/8 tests)
100
94
 
101
95
  Summary
102
96
  ┌─────────────┬────────┬──────────┬───────────────┬───────┬───────┬──────┬──────┬──────┬───────────┐
@@ -105,19 +99,11 @@ Summary
105
99
  │ contact │ 'PASS' │ '2.6s' │ '0.9s' │ '35' │ '35' │ '0' │ '0' │ '0' │ '0' │
106
100
  │ scanner │ 'PASS' │ '10.1s' │ '8.7s' │ '162' │ '161' │ '0' │ '1' │ '0' │ '0' │
107
101
  │ tarball │ 'PASS' │ '1.8s' │ '0.7s' │ '77' │ '77' │ '0' │ '0' │ '0' │ '0' │
108
- │ mama │ 'PASS' │ '1.2s' │ '0.1s' │ '85' │ '85' │ '0' │ '0' │ '0' │ '0' │
109
102
  │ tree-walker │ 'PASS' │ '3.0s' │ '2.0s' │ '26' │ '26' │ '0' │ '0' │ '0' │ '0' │
110
- │ conformance │ 'PASS' │ '1.1s' │ '0.1s' │ '35' │ '35' │ '0' │ '0' │ '0' │ '0' │
111
- │ i18n │ 'PASS' │ '1.1s' │ '0.2s' │ '19' │ '19' │ '0' │ '0' │ '0' │ '0' │
112
- │ rc │ 'PASS' │ '4.1s' │ '0.6s' │ '28' │ '28' │ '0' │ '0' │ '0' │ '0' │
113
- │ utils │ 'PASS' │ '1.1s' │ '0.1s' │ '30' │ '30' │ '0' │ '0' │ '0' │ '0' │
114
103
  │ flags │ 'PASS' │ '1.1s' │ '0.1s' │ '9' │ '9' │ '0' │ '0' │ '0' │ '0' │
115
- │ fs-walk │ 'PASS' │ '1.1s' │ '0.1s' │ '3' │ '3' │ '0' │ '0' │ '0' │ '0' │
116
- │ github │ 'PASS' │ '2.9s' │ '2.0s' │ '8' │ '8' │ '0' │ '0' │ '0' │ '0' │
117
- │ gitlab │ 'PASS' │ '4.3s' │ '3.3s' │ '8' │ '8' │ '0' │ '0' │ '0' │ '0' │
118
104
  └─────────────┴────────┴──────────┴───────────────┴───────┴───────┴──────┴──────┴──────┴───────────┘
119
105
 
120
- 13/13 workspaces passed.
106
+ 5/5 workspaces passed.
121
107
  ```
122
108
 
123
109
  ### Summary columns
@@ -236,17 +222,11 @@ workspace already running when the failure is detected runs to completion
236
222
 
237
223
  ## Why
238
224
 
239
- `npm run test --workspaces --if-present` runs every workspace but gives you
240
- no aggregated summary and no way to fail fast early. An early failure just
241
- scrolls off screen once later workspaces print their own output. sumlyzer is
242
- a small, dependency-free tool that solves just this.
243
-
244
- This exact fail-fast behavior at the `--workspaces` level has been requested
245
- from npm more than once:
246
- [npm/rfcs#575](https://github.com/npm/rfcs/issues/575) (open) and
247
- [npm/rfcs#602](https://github.com/npm/rfcs/issues/602) (closed). Until it
248
- lands (if it ever does), sumlyzer's `--ff` flag gets you there — see also
249
- this [Stack Overflow answer](https://stackoverflow.com/questions/71300870/npm-workspace-command-does-not-stop-executing-when-command-fails-for-a-workspace/79989284#79989284)
225
+ This fail-fast behavior at the `--workspaces` level has been requested from
226
+ npm more than once: [npm/rfcs#575](https://github.com/npm/rfcs/issues/575)
227
+ (open) and [npm/rfcs#602](https://github.com/npm/rfcs/issues/602) (closed).
228
+ Until it lands, sumlyzer's `--ff` flag gets you there — see also this
229
+ [Stack Overflow answer](https://stackoverflow.com/questions/71300870/npm-workspace-command-does-not-stop-executing-when-command-fails-for-a-workspace/79989284#79989284)
250
230
  on the same problem.
251
231
 
252
232
  ## Contributing
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sumlyzer",
3
- "version": "0.5.0",
3
+ "version": "0.5.1",
4
4
  "description": "Run every npm workspace's test script, only show output for the ones that fail, and finish with an aggregated pass/fail summary.",
5
5
  "type": "module",
6
6
  "bin": {