initialise some members properly
remove .c_str() redundancy
fix a bunch of unrelated errors in TODO test scripts
add CASE statement