Added some test reporting code - unfinished.