Move methods into helper module so we can stub them more easily.
Add tests for remove action
Write tests for the upgrade action