Fix unit tests to exit with the correct return code
Add unit test for adding a missing package

This fails at the moment because the expected behaviour is not yet implemented.

Re: #20