masaori335 opened a new pull request, #13699:
URL: https://github.com/apache/trafficserver/pull/13699
Render every corpus input's AST back to hrw4u and require the compiled
config to be unchanged: whatever the AST drops, the config loses too. Unlike
hand-written cases, nothing has to be enumerated in advance.
```
corpus .hrw4u --parse--> AST --unparse--> regenerated .hrw4u
| |
emit emit
| |
v v
config <----------- must match ------------> config
```
It found five losses, all fixed here:
- an empty `else { }` looked like no else clause, so a sandbox policy
denying 'else' was evaded by writing one
- comments were discarded, though five .conf goldens carry them
- a bool assignment lost the spelling the emitter echoes back
- parentheses were unwrapped, dropping the cond %{GROUP} they emit
- a set and an iprange both became a tuple of IPValue, though in [1.2.3.4]
emits (1.2.3.4) and in {1.2.3.4} emits {1.2.3.4}
IfBlock.has_else is required rather than defaulted, so a site that rebuilds
the node and forgets it fails instead of reopening the bypass.
A second test asserts the corpus reaches every grammar rule; a bare $param
value had no fixture, now added.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]