Improvements to the testing machinery, including the replay option.