Fix a brain-o in _proc_uri()

The loop variable was "prefix", but wrote "uri" instead.
Add tests on _proc_uri().
Add tests on _proc_ctype_header().
Synchronize with _proc_ctype_header() for testing consistency.
Add tests for _proc_accept_header().