Add testing project, start testing various bits of the parser

This also includes changing basically all the parse functions to Active
Patterns, and attempting to unify the interfaces so everything takes a
string, and returns the remaining text as a string.