More refactoring to make testing easier - testing interrupt/resume of long operations