This method should only be called by Executor implementations before executing the work associated with the Future and by unit tests.
set_running_or_notify_cancel()