Cleaning up test code - adding explicit passed or failed indicator;  merging some variable declaration and initializations.