More tests and fixes

- Validate special cases for matching input.
- Process string values in GrammarConstant for special input. (I though
I had done this already)
- More tests.