Class: ODDB::FiPDF::TestFormat::StubWriter
- Defined in:
- ext/fipdf/test/format_test.rb
Instance Attribute Summary collapse
-
#add_text_wrap_results ⇒ Object
Returns the value of attribute add_text_wrap_results.
-
#height ⇒ Object
Returns the value of attribute height.
-
#num_lines ⇒ Object
Returns the value of attribute num_lines.
Instance Method Summary collapse
- #add_text_wrap(*args) ⇒ Object
- #font_height(*args) ⇒ Object
-
#initialize ⇒ StubWriter
constructor
A new instance of StubWriter.
- #select_font(*args) ⇒ Object
Constructor Details
#initialize ⇒ StubWriter
Returns a new instance of StubWriter.
17 18 19 20 |
# File 'ext/fipdf/test/format_test.rb', line 17 def initialize @add_text_wrap_results = [] @calls = 0 end |
Instance Attribute Details
#add_text_wrap_results ⇒ Object
Returns the value of attribute add_text_wrap_results.
16 17 18 |
# File 'ext/fipdf/test/format_test.rb', line 16 def add_text_wrap_results @add_text_wrap_results end |
#height ⇒ Object
Returns the value of attribute height.
16 17 18 |
# File 'ext/fipdf/test/format_test.rb', line 16 def height @height end |
#num_lines ⇒ Object
Returns the value of attribute num_lines.
16 17 18 |
# File 'ext/fipdf/test/format_test.rb', line 16 def num_lines @num_lines end |
Instance Method Details
#add_text_wrap(*args) ⇒ Object
23 24 25 26 27 28 29 30 |
# File 'ext/fipdf/test/format_test.rb', line 23 def add_text_wrap(*args) @calls += 1 if (@calls >= 2) "" else "foo" end end |
#font_height(*args) ⇒ Object
31 32 33 |
# File 'ext/fipdf/test/format_test.rb', line 31 def font_height(*args) @height end |
#select_font(*args) ⇒ Object
21 22 |
# File 'ext/fipdf/test/format_test.rb', line 21 def select_font(*args) end |