Sha256: 5215ce6abe72d5973831af4adb70dc66806f5e077da755f8c8b9802b17c01de2

Contents?: true

Size: 866 Bytes

Versions: 1

Compression:

Stored size: 866 Bytes

Contents

#  _____         _
# |_   _|__  ___| |_
#   | |/ _ \/ __| __|
#   | |  __/\__ \ |_
#   |_|\___||___/\__|
#
# for lib/facet/string/quote.rb
#
# Extracted Wed Jan 25 11:25:39 EST 2006
# Unit Tools Reap Test Extractor
#

require 'facet/string/quote.rb'


  require 'test/unit'

  class TCString < Test::Unit::TestCase

    def setup
      @a =  "hi"
    end

    def test_001
      assert_raises( ArgumentError ) { @a.quote(1,2) }
    end

    def test_002
      assert_equal( %{'hi'}, @a.quote )
    end

    def test_003
      assert_equal( %{"hi"}, @a.quote(:d) )
      assert_equal( %{"hi"}, @a.quote(:double) )
    end

    def test_004
      assert_equal( %{'hi'}, @a.quote(:s) )
      assert_equal( %{'hi'}, @a.quote(:single) )
    end

    def test_005
      assert_equal( %{`hi`}, @a.quote(:b) )
      assert_equal( %{`hi`}, @a.quote(:back) )
    end

  end


Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
facets-1.0.3 packages/core/test/lib/facet/string/test_quote.rb