Move some of the sanity testing harness outside.
Started to convert stage.
Merge.