added test for cancelling asynchronously