compiling again. refactor common test paths.

Now using a test harness with randomness.