Created
January 16, 2024 01:08
-
-
Save fadhlirahim/ee57d9e37d5fa7c38f9052991002d709 to your computer and use it in GitHub Desktop.
Reading ruby gem vcr cassette binary
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'yaml' | |
require 'oj' | |
path = 'spec/vcr_cassettes/cassette.yml' | |
loaded = YAML.load_file(path) | |
body_string = loaded['http_interactions'][0]['response']['body']['string'] | |
Oj.load(body_string) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment