From d3a642763aa8501bfd53ce4713d7b44b7c92020e Mon Sep 17 00:00:00 2001 From: Marat Radchenko Date: Sun, 12 May 2024 15:17:57 +0300 Subject: [PATCH] fix gepub 1.0.16 compatibility --- spec/spec_helper.rb | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 25a46d9..d7f4107 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -80,8 +80,12 @@ def to_epub(input, opts = {}) return result if result.is_a?(GEPUB::Book) output = Pathname.new result.attr('outfile') - book = GEPUB::Book.parse output - [book, output] + [ + output.open do |f| + GEPUB::Book.parse f + end, + output + ] end end