gitlabhq/gitlab-shell — pull request #16 by docwhat (2013-03-15 17:21:53+00:00)
Title: Improve gitlab_shell spec and replace `system()` with `exec()`

I mainly cleaned up the tests so that I could replace `system()` with `exec()`.

We don't need to run any ruby after determining that the user is allowed, so using `exec()` makes sense.

The test cleanups are mainly:

* Using mocks to test things that would be harder to test otherwise.
* Randomizing some values to ensure that we're not inheriting values from previous tests.
* Increasing the coverage.
* Don't rely on `config.yml` being the `config.yml.example`