Sha256: 780b69add5e477c4edd68da4a05c2cfa77bb475b510954b7839b63c1bcf6d1b8

Contents?: true

Size: 585 Bytes

Versions: 1

Compression:

Stored size: 585 Bytes

Contents

require 'abstract_unit'
require 'active_support/core_ext/cgi'

class EscapeSkippingSlashesTest < Test::Unit::TestCase
  def test_array
    assert_equal 'hello/world', CGI.escape_skipping_slashes(%w(hello world))
    assert_equal 'hello+world/how/are/you', CGI.escape_skipping_slashes(['hello world', 'how', 'are', 'you'])
  end

  def test_typical
    assert_equal 'hi', CGI.escape_skipping_slashes('hi')
    assert_equal 'hi/world', CGI.escape_skipping_slashes('hi/world')
    assert_equal 'hi/world+you+funky+thing', CGI.escape_skipping_slashes('hi/world you funky thing')
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
recliner-0.0.1 vendor/activesupport/test/core_ext/cgi_ext_test.rb