Added timeXXX and assert methods. More unit testing.