Sha256: 2fcd4972e41fccc7f504eb63c18691c2a05b59eb83e0211b562856b412938a71
Contents?: true
Size: 1.05 KB
Versions: 1
Compression:
Stored size: 1.05 KB
Contents
require File.dirname(__FILE__) + '/../../spec_helper.rb' module PDF class Writer def save_as(path) #no op end end end describe PDF::Storycards::Writer do before(:all) do multiple_stories_path = File.dirname(__FILE__) + '/../../calculator_stories' @story_text = File.read(multiple_stories_path) end it "should not print border when printing 1-up" do PDF::Storycards::Writer.should_not_receive(:print_border) PDF::Storycards::Writer.make_pdf(@story_text, :output => 'storycards.pdf', :style => :card_1up) end it "should not print border when printing 4-up with default options" do PDF::Storycards::Writer.should_not_receive(:print_border) PDF::Storycards::Writer.make_pdf(@story_text, :output => 'storycards.pdf', :style => :letter_4up) end it "should print border when printing 4-up with border option set to true" do PDF::Storycards::Writer.should_receive(:print_border).twice PDF::Storycards::Writer.make_pdf(@story_text, :output => 'storycards.pdf', :style => :letter_4up, :borders => true) end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
pdf-storycards-0.1.0 | spec/pdf/storycards/writer_spec.rb |