Sha256: f63fcbdcc8f9a8364a8bb24087e538dfb831e89d92a4eec2713e9b3d40f949a6

Contents?: true

Size: 657 Bytes

Versions: 1

Compression:

Stored size: 657 Bytes

Contents

#  _____         _
# |_   _|__  ___| |_
#   | |/ _ \/ __| __|
#   | |  __/\__ \ |_
#   |_|\___||___/\__|
#
# for lib/facets/more/ansicode.rb
#
# Extracted Wed Aug 23 18:22:52 EDT 2006
# Unit Tools Reap Test Extractor
#

require 'facets/more/ansicode.rb'


  require 'test/unit'

  class TC_ANSICode < Test::Unit::TestCase

    include Console::ANSICode

    def test_methods
      str = red + "Hello" + blue + "World"
      out = "\e[31mHello\e[34mWorld"
      assert_equal( out, str )
    end

    def test_blocks
      str = red { "Hello" } + blue { "World" }
      out = "\e[31mHello\e[0m\e[34mWorld\e[0m"
      assert_equal( out, str )
    end

  end


Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
facets-1.7.30 test/lib/facets/more/test_ansicode.rb