bbatsov/rubocop — pull request #522 by bquorning (2013-09-30 20:16:54+00:00)
Title: Refactor specs

This PR will fix #430, and also does a bit of cleanup:

* Don't explicitly define namespace modules in the spec – just include the namespace when calling `describe`.
* The subject (in Cop specs) is always named "cop".
* The spec offence messages are referenced by their literal string, not by the constant referring to said string.
* Use `described_class` where possible.

The `favor_modifier_spec.rb` needed special attention, so please pay special attention to its diff.

This turned out to be a huge pull request, since I changed the indentation of most of the specs… It's easiest to review each commit separately, and I have a feeling that maybe it should be split into 2 or 3 separate pull requests.