Allow a test to identify whether it runs in isolation.

A custom setup of test fixtures may use this indicator to skip additional performance optimizations that only make sense if multiple tests are executed in the same process.
Merge pull request #1360 from sun/istestinisolation

Allow a test to identify whether it runs in isolation
Fix #1351: Add back TestFailure::failedTest() for BC.