Commit 1b72ab2
authored
test: check daemon unmarshal errors (#1296)
## What?
- Check JSON unmarshal errors in daemon handler tests.
- Fail clearly when a response body cannot be decoded instead of
ignoring the error.
- Keep the change limited to daemon tests.
## Why?
Ignoring `json.Unmarshal` errors can let malformed test responses pass
into later assertions with less useful failures. This makes the daemon
tests report decode problems at the source.
Fixes #7181 parent 4876a93 commit 1b72ab2
1 file changed
Lines changed: 6 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
99 | 99 | | |
100 | 100 | | |
101 | 101 | | |
102 | | - | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
103 | 105 | | |
104 | 106 | | |
105 | 107 | | |
| |||
115 | 117 | | |
116 | 118 | | |
117 | 119 | | |
118 | | - | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
119 | 123 | | |
120 | 124 | | |
121 | 125 | | |
| |||
0 commit comments