rearranged tests

to follow new instructions on using testthat here:

http://adv-r.had.co.nz/Testing.html