Added a test helper to test execution time.

Updated relevant tests to use it.