Commit b444beb
committed
dastest: quote spaced args in launchPrefix + regression test + typo (Copilot)
Address Copilot review on PR #2897:
1. Quoting (#3308736517): launchPrefix builds singleTest as a space-joined string. When any preserved pre-`--` arg contains a space (e.g. `-load_module "C:\Program Files\daslang/dasImgui"`), popen's shell-split on the other side breaks the boundary. Pre-fix this was a latent risk on raw_args[0]/raw_args[1] too; extending preservation to all pre-`--` args makes it more likely. Wrap each space-containing arg in double quotes — both cmd.exe and /bin/sh honor double-quote-wrapped args.
2. Regression test (#3308736537): add a second subtest in test_isolated_mode that spawns dastest with a pre-`--` `-dasroot {get_das_root()}` (no-op value) and runs against a new _isolated_fixture_pre_dashdash/ subdir whose fixture test asserts -dasroot is in get_command_line_arguments(). Catches any regression of the launchPrefix reconstruction.
3. Typo (#3308736556): "Findex" → "Find index" in the launchPrefix comment.
Verified: full dastest sweep 9/9 pass (was 8/8, +1 new subtest).1 parent 335e173 commit b444beb
3 files changed
Lines changed: 53 additions & 6 deletions
File tree
- dastest
- tests
- _isolated_fixture_pre_dashdash
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
395 | 395 | | |
396 | 396 | | |
397 | 397 | | |
398 | | - | |
| 398 | + | |
399 | 399 | | |
400 | | - | |
| 400 | + | |
| 401 | + | |
| 402 | + | |
401 | 403 | | |
402 | 404 | | |
403 | 405 | | |
404 | 406 | | |
405 | 407 | | |
| 408 | + | |
| 409 | + | |
406 | 410 | | |
| 411 | + | |
407 | 412 | | |
408 | 413 | | |
409 | 414 | | |
| |||
Lines changed: 23 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
18 | | - | |
19 | | - | |
20 | | - | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
21 | 23 | | |
22 | 24 | | |
23 | 25 | | |
| |||
33 | 35 | | |
34 | 36 | | |
35 | 37 | | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
36 | 55 | | |
37 | 56 | | |
38 | | - | |
| 57 | + | |
39 | 58 | | |
40 | 59 | | |
41 | 60 | | |
| |||
0 commit comments