tests/grovel: rewrite tests for bug-1395242

The tests for bug-1395242 have been expanded to include:
- testing for grovelled base types.
- a wider range of constants are now checked.
grovel: fix bug-1395242

... and permit grovelling of base types used in CONSTANTENUM and CENUM
forms.
grovel: refactor convert-intmax-constant
grovel: refactor foreign-type-to-printf-specification
tests/grovel: minor cosmetic tweaks to bug-1395242