Sha256: 3d58c62b1b9d2433a6fcf49574ea885395006682bb4e9df6cc6c16c28bd1e977

Contents?: true

Size: 577 Bytes

Versions: 19

Compression:

Stored size: 577 Bytes

Contents

require File.dirname(__FILE__) + '/test_helper.rb'

class TestOauth < Test::Unit::TestCase

  def test_parameter_escaping_kcode_invariant
    old = $KCODE
    begin
      %w(n N e E s S u U).each do |kcode|
        $KCODE = kcode
        assert_equal '%E3%81%82', OAuth::Helper.escape('あ'),
                      "Failed to correctly escape Japanese under $KCODE = #{kcode}"
        assert_equal '%C3%A9', OAuth::Helper.escape('é'),
                      "Failed to correctly escape e+acute under $KCODE = #{kcode}"
      end
    ensure
      $KCODE = old
    end
  end
end

Version data entries

19 entries across 19 versions & 11 rubygems

Version Path
greut-oauth-0.3.6 test/test_signature.rb
mojodna-oauth-0.3.2.2 test/test_signature.rb
mojodna-oauth-0.3.3 test/test_signature.rb
mojodna-oauth-0.3.4.1 test/test_signature.rb
mojodna-oauth-0.3.4 test/test_signature.rb
mojodna-oauth-0.3.5 test/test_signature.rb
mojodna-oauth-0.3.6 test/test_signature.rb
monkeyhelper-oauth-0.3.5 test/test_signature.rb
mzsanford-oauth-0.3.2.2 test/test_signature.rb
pelle-oauth-0.3.5 test/test_signature.rb
sporkd-oauth-0.3.6 test/test_signature.rb
af-oauth-0.3.4.1 test/test_signature.rb
sutto-oauth-0.3.6 test/test_signature.rb
gregwebs-oauth-0.3.6.1 test/test_signature.rb
typhoauth-0.3.6.1 test/test_signature.rb
oauth-0.3.6 test/test_signature.rb
oauth-0.3.5 test/test_signature.rb
oauth-0.3.4 test/test_signature.rb
oauth-0.3.3 test/test_signature.rb