Commit 917279b
committed
Fix --test for d8 shell runner
There seems to be two bugs when running
`d8 cli.js -- --test <subset>`:
1. A typo in cli.js (`cliParams.get("tests")` should've been
`cliParams.get("test")`) which leads to
```
cli.js:122: TypeError: Cannot read properties of undefined (reading 'split')
let tests = cliParams.has("test") ? cliParams.get("tests").split(",") : []
^
TypeError: Cannot read properties of undefined (reading 'split')
at cli.js:122:63
```
2. performance.mark/performance.measure in d8 requires PerformanceMark
objects as arguments and do not take mark name strings.
```
console.error: JetStream3 failed: Error: Invalid 'startMark' argument: Not an Object
console.error: Error: Invalid 'startMark' argument: Not an Object
at Driver.start (./JetStreamDriver.js:352:25)
at async runJetStream (cli.js:135:9)
cli.js:141: Error: Invalid 'startMark' argument: Not an Object
```
This patch fixes the typo in 1. For 2, since these are only used for
UI annotations, replace them with no-ops in d8 instead.1 parent de88e36 commit 917279b
2 files changed
+6
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
119 | 119 | | |
120 | 120 | | |
121 | 121 | | |
122 | | - | |
| 122 | + | |
123 | 123 | | |
124 | 124 | | |
125 | 125 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
55 | 55 | | |
56 | 56 | | |
57 | 57 | | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
0 commit comments