added tests and all sorts of fun

i loathe testing. stupid crapwhore.