Sha256: 0f5e168919d7d6a3a69a220ccf76d520d50e2220ee0d726f035f12ecd9602b70
Contents?: true
Size: 797 Bytes
Versions: 2
Compression:
Stored size: 797 Bytes
Contents
# coding: utf-8 require 'test_helper' class Thinreports::Core::Shape::PageNumber::TestInterface < Minitest::Test include Thinreports::TestHelper PageNumber = Thinreports::Core::Shape::PageNumber def create_pageno(format = {}) report = Thinreports::Report.new layout: layout_file.path parent = report.start_new_page PageNumber::Interface.new parent, PageNumber::Format.new(format) end def test_format pageno = create_pageno 'format' => '{page}' assert_equal pageno.format, '{page}' pageno.format('{page} / {total}') assert_equal pageno.format, '{page} / {total}' end def test_reset_format pageno = create_pageno 'format' => '{page}' pageno.format('-- {page} --') pageno.reset_format assert_equal pageno.format, '{page}' end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
thinreports-0.9.1 | test/unit/core/shape/page_number/test_interface.rb |
thinreports-0.9.0 | test/unit/core/shape/page_number/test_interface.rb |