Record your test suite's HTTP interactions and replay them during future test runs for fast, deterministic, accurate tests. We're looking for more maintainers. If you'd like to help maintain a well-used gem please spend some time reviewing pull requests, issues, or participating in discussions. VCR will replay the response from iana.org when the HTTP request is made. This test is now fast (no real HTTP requests are made anymore), deterministic (the test will continue to pass, even if you are offline, or iana.org goes down for maintenance) and accurate (the response will contain the same headers and body you get from a real request). You can use a different cassette library directory (e.g., "test/vcr_cassettes"). The recorded requests and responses are stored on disk in a serialization format of your choice (currently YAML and JSON are built in, and you can easily implement your own custom serializer) and can easily be inspected and edited.

Features

  • Automatically records and replays your HTTP interactions with minimal setup/configuration code
  • Supports and works with the HTTP stubbing facilities of multiple libraries
  • Supports multiple HTTP libraries
  • Request matching is configurable based on HTTP method, URI, host, path, body and headers, or you can easily implement a custom request matcher to handle any need
  • The same request can receive different responses in different tests--just use different cassettes
  • Dynamic responses are supported using ERB

Project Samples

Project Activity

See All Activity >

Follow vcr

vcr Web Site

Other Useful Business Software
Stay in Flow. Let Zenflow Handle the Heavy Lifting. Icon
Stay in Flow. Let Zenflow Handle the Heavy Lifting.

Your AI engineering control center. Zenflow turns specs into shipped features using parallel agents and multi-repo intelligence.

Zenflow is your engineering control center, turning specs into shipped features. Parallel agents handle coding, testing, and refactoring with real repo context. Multi-agent workflows remove bottlenecks and automate routine work so developers stay focused and in flow.
Try free now
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of vcr!

Additional Project Details

Programming Language

Ruby

Related Categories

Ruby Software Testing Tool, Ruby JSON Serialization Libraries

Registered

2021-10-22