Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
#39
This PR replaces
rspec-rails
withrspec
, and removes theactivesupport
dependency, which should make it easier to use this gem outside of a Rails environment. As a nice bonus, it also reduces the total number of gem dependencies (as reported bybundle install
) from 35 to 15.There were only 2 methods provided by ActiveSupport that were being used:
Module#mattr_accessor
andString#strip_heredoc
. Formattr_accessor
, I've added a (roughly) equivalent implementation, minus the instance-level getter and setter methods (which we presumably don't want anyway). As forstrip_heredoc
, I've just copied the implementation from ActiveSupport into a private method insideJsonMatchers::RSpec
. Personally I'd de-indent the heredocs and live with the ugliness, but to each their own.Anyway, thank you for writing this gem. I've used it in a bunch of projects when I needed to test my JSON APIs, and it's been hugely helpful :)