Commit f163dc2
authored
[test] Improve stdout/stderr capturing for browser tests. NFC (#24174)
Now you just need to edit one line in browser_reporting.js to have
stdout/stderr sent back to the server.
This makes debugging issues, especially in headless mode, much simpler.
Ideally I'd like to make this even easier (e.g. enabled via a command
line flag), but this is a good step in the right direction.
I made this change while trying to invesitgate flakiness in
`test_sdl_mouse`. The ouput from that test with this logging enabled now
looks like this:
```
test_sdl_mouse (test_browser.browser.test_sdl_mouse) ... 127.0.0.1 - - [23/Apr/2025 10:42:49] code 404, message File not found
[client stderr: 'motion: abs:10,20 rel:10,20']
[client stderr: 'button down: 1,1 10,20']
[client stderr: 'button up: 1,0 10,20']
[client stderr: 'motion: abs:30,77 rel:20,57']
ok
[Browser harness server terminated]
```1 parent 3b72132 commit f163dc2
2 files changed
+39
-12
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
1 | 4 | | |
2 | 5 | | |
3 | 6 | | |
4 | 7 | | |
5 | 8 | | |
6 | 9 | | |
7 | 10 | | |
8 | | - | |
| 11 | + | |
9 | 12 | | |
10 | 13 | | |
11 | 14 | | |
| |||
29 | 32 | | |
30 | 33 | | |
31 | 34 | | |
32 | | - | |
| 35 | + | |
33 | 36 | | |
34 | 37 | | |
35 | 38 | | |
36 | 39 | | |
37 | 40 | | |
38 | 41 | | |
39 | 42 | | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
40 | 51 | | |
41 | 52 | | |
42 | 53 | | |
| |||
89 | 100 | | |
90 | 101 | | |
91 | 102 | | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
92 | 118 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2120 | 2120 | | |
2121 | 2121 | | |
2122 | 2122 | | |
2123 | | - | |
| 2123 | + | |
| 2124 | + | |
| 2125 | + | |
2124 | 2126 | | |
2125 | 2127 | | |
2126 | 2128 | | |
| |||
2160 | 2162 | | |
2161 | 2163 | | |
2162 | 2164 | | |
2163 | | - | |
2164 | | - | |
2165 | | - | |
2166 | | - | |
2167 | | - | |
2168 | | - | |
2169 | | - | |
2170 | | - | |
| 2165 | + | |
| 2166 | + | |
| 2167 | + | |
| 2168 | + | |
| 2169 | + | |
| 2170 | + | |
| 2171 | + | |
2171 | 2172 | | |
2172 | 2173 | | |
2173 | 2174 | | |
2174 | | - | |
| 2175 | + | |
2175 | 2176 | | |
2176 | 2177 | | |
2177 | 2178 | | |
| |||
0 commit comments