Sha256: 83ae3585b0ca1f5760f388b0d3059a943aa383dadf3e86505e789f65f907821d
Contents?: true
Size: 655 Bytes
Versions: 19
Compression:
Stored size: 655 Bytes
Contents
require File.join(File.dirname(__FILE__), 'test_helper') describe "auto table" do it "converts nonarrays to arrays and renders" do require 'set' expected_table = <<-TABLE.unindent +-------+ | value | +-------+ | 1 | | 2 | | 3 | +-------+ 3 rows in set TABLE Helpers::AutoTable.render(::Set.new([1,2,3])).should == expected_table end it "renders hash" do expected_table = <<-TABLE.unindent +---+-------+ | 0 | 1 | +---+-------+ | a | 12345 | +---+-------+ 1 row in set TABLE Helpers::AutoTable.render({:a=>12345}).should == expected_table end end
Version data entries
19 entries across 19 versions & 3 rubygems