New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Spec reorganization and updating #6

Merged
merged 8 commits into from Aug 22, 2013

Conversation

Projects
None yet
2 participants
@rspeicher
Contributor

rspeicher commented Aug 20, 2013

Adds VCR for handling live data to test against. - Closes #3

Also reorganizes some files and specs; see individual commits for reasoning, particularly 3254fbe. Hope that's cool.

rspeicher added some commits Aug 19, 2013

Move specs to a rapgenius subfolder
`lib/rapgenius/foo.rb` should have a `spec/rapgenius/foo_spec.rb` file.
Drop webmock requirement to 1.11.0
VCR spits out a warning about higher versions. It still seemed to work
but I hated seeing the message.
Update Song's spec
- Replaced `:fetch` stubbing with VCR cassettes
- Removed unneccessary testing of the `find` method.
- Broke some one-liner tests into `describe` blocks where there was a
  clear relation between multiple tests.
Minor reorganization of Scraper; update Scraper specs
Introduces a 'Client' class that includes HTTParty and then sets some
sane defaults for all of the lib's requests. I kept the Scraper module
in tact and just updated it to use this new Client class so that
`include RapGenius::Scraper` in Song and Annotation still worked.

Where possible I kept everything the same for backwards-compatibility
until @timrogers wants to change things.

Also updated are the specs for the module. Removed some specs that were
basically testing low-level HTTParty stuff.
@timrogers

This comment has been minimized.

Show comment
Hide comment
@timrogers

timrogers Aug 21, 2013

Owner

Thanks for your PRs @tsigo, and sorry that I haven't reviewed and merged yet, been super busy at work. It's on my to-do list, and should get done tomorrow!

Owner

timrogers commented Aug 21, 2013

Thanks for your PRs @tsigo, and sorry that I haven't reviewed and merged yet, been super busy at work. It's on my to-do list, and should get done tomorrow!

timrogers pushed a commit that referenced this pull request Aug 22, 2013

Tim Rogers
Merge pull request #6 from tsigo/vcr
Spec reorganization and updating

@timrogers timrogers merged commit 0b4bfe4 into timrogers:master Aug 22, 2013

@rspeicher rspeicher deleted the rspeicher:vcr branch Aug 22, 2013

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment