add cancel unit tests.