Sha256: 2f2e32915e3d5c52c4506a1ba71336563679afd69940fc4adc7aec17119ca518
Contents?: true
Size: 707 Bytes
Versions: 4
Compression:
Stored size: 707 Bytes
Contents
#! /usr/bin/env ruby # coding: utf-8 require "helper" require "stringio" class Tefil::IndentConverter public :process_stream end class TC_IndentStatistics < Test::Unit::TestCase def setup @is00 = Tefil::IndentStatistics.new() end def test_process_stream # stdin -> stdout $stdin = StringIO.new $stdin.puts "a" $stdin.puts " b" $stdin.puts " c" $stdin.puts " d" $stdin.puts " e" $stdin.puts " f" $stdin.puts " g" $stdin.puts " h" $stdin.rewind #str = capture_stdout{} result = capture_stdout{ @is00.filter([])} correct = " 0|*\n" + " 2|***\n" + " 4|****\n" assert_equal(correct, result) end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
tefil-0.1.5 | test/test_indentstatistics.rb |
tefil-0.1.4 | test/test_indentstatistics.rb |
tefil-0.1.3 | test/test_indentstatistics.rb |
tefil-0.1.2 | test/test_indentstatistics.rb |