Sha256: b5295fce4352be09c28d43c94cf1156bdfcbeaf95d861a69ae421be389d3627b

Contents?: true

Size: 411 Bytes

Versions: 1

Compression:

Stored size: 411 Bytes

Contents

module TestDocumentHelper
  def status_line(status)
    text "Status: #{status}"
  end
end

class TestDocument < PrawnCocktail::Document
  helper TestDocumentHelper
  initialize_document { text "Init works." }

  def initialize(status)
    @status = status
  end

  private

  def data
    { status: @status }
  end
end

class SubTestDocument < TestDocument
  initialize_document { text "Sub-init works." }
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
prawn_cocktail-0.5.4 spec/fixtures/document.rb