Sha256: 99a67e15abe7d736d614231c1f9c1cea162f54ff32b0fa940889705c061cdbce
Contents?: true
Size: 631 Bytes
Versions: 1
Compression:
Stored size: 631 Bytes
Contents
require 'test_helper' class ZafuTest < Zena::View::TestCase include Zena::Use::Zafu::ViewMethods include Zena::Use::Zafu::ControllerMethods def test_page_numbers s = "" page_numbers(2, 3, ',') {|p,j| s << "#{j}#{p}"} assert_equal "1,2,3", s s = "" page_numbers(2, 30, ',') {|p,j| s << "#{j}#{p}"} assert_equal "1,2,3,4,5,6,7,8,9,10", s s = "" page_numbers(14, 30, ',') {|p,j| s << "#{j}#{p}"} assert_equal "10,11,12,13,14,15,16,17,18,19", s s = "" page_numbers(28, 30, ' | ') {|p,j| s << "#{j}#{p}"} assert_equal "21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30", s end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
zena-0.15.0 | test/unit/zena/use/zafu_test.rb |