Implement test and fix for #8

Had to completely rearrange the test framework because too much was interacting with the `EditorView` class to ignore it anymore. Found out from the [Find and Replace package](https://github.com/atom/find-and-replace/blob/master/spec/results-view-spec.coffee#L23-26) how to attach an `EditorView` to the headless test infrastructure. This slows down the tests, so I only implemented it for the tests that really needed it. (Hence why all the rearranging.)