diff --git a/manual/basic_concepts/view.rb b/manual/basic_concepts/view.rb index 7dad733b7..4922bfe24 100644 --- a/manual/basic_concepts/view.rb +++ b/manual/basic_concepts/view.rb @@ -29,6 +29,10 @@ def initialize(name) @name = name end + def document + @document ||= Prawn::Document.new(page_size: 'A4', page_layout: :landscape, margin: 30) + end + def say_hello text "Hello, #{@name}!" end diff --git a/spec/prawn_manual_spec.rb b/spec/prawn_manual_spec.rb index 105016409..a001d4e73 100644 --- a/spec/prawn_manual_spec.rb +++ b/spec/prawn_manual_spec.rb @@ -6,9 +6,9 @@ MANUAL_HASH = case RUBY_ENGINE when 'ruby' - '7991e4f72e944140840e1c26f0fff331029846eaab148de8483d06491c7808bc4963e8e7376a514e855037f1f1b4197877a31f2df44f511f4f7f5e0ce5df3170' + 'ab45a1e814006cb04928f8d0f6c9d0a409c90ffb41dc2fd10e3558e7b314fb99d2a0f5aa29b89a6ae855eaa4ed9840620abbc8bab9c48991aa7f69a98550fa79' when 'jruby' - '29b8f8cb00910426805ce226fb47c59d6409683f35f0d2c056a6cf837ba086ca5c763ff89266cfc8e11b1d92af60c9974822b12ad761cdbdf520adb005a98750' + '695d3d8fa4daae26726fd3db1da4d0f3552c3d406146bc0ef4094ae7e177b0d16c77bc1d157318e69579bcd613655d16e874627d015428dab5ae50d79e2aea2c' end RSpec.describe Prawn do