adding unit test for cancelOperation: