moving some things about, some basic tests and some code for the parse
function