Class: TC_Unquoter

Inherits:
Test::Unit::TestCase
  • Object
show all
Defined in:
lib/action_mailer/vendor/tmail/quoting.rb

Instance Method Summary collapse

Instance Method Details

#test_unquote_base64Object



119
120
121
122
123
# File 'lib/action_mailer/vendor/tmail/quoting.rb', line 119

def test_unquote_base64
  a ="=?ISO-8859-1?B?WzE2NjQxN10gQmVrcuZmdGVsc2UgZnJhIFJlanNlZmViZXI=?="
  b = TMail::Unquoter.unquote_and_convert_to(a, 'utf-8')
  assert_equal "[166417] Bekr\303\246ftelse fra Rejsefeber", b
end

#test_unquote_quoted_printableObject



113
114
115
116
117
# File 'lib/action_mailer/vendor/tmail/quoting.rb', line 113

def test_unquote_quoted_printable
  a ="=?ISO-8859-1?Q?[166417]_Bekr=E6ftelse_fra_Rejsefeber?=" 
  b = TMail::Unquoter.unquote_and_convert_to(a, 'utf-8')
  assert_equal "[166417] Bekr\303\246ftelse fra Rejsefeber", b
end

#test_unquote_without_charsetObject



125
126
127
128
129
# File 'lib/action_mailer/vendor/tmail/quoting.rb', line 125

def test_unquote_without_charset
  a ="[166417]_Bekr=E6ftelse_fra_Rejsefeber" 
  b = TMail::Unquoter.unquote_and_convert_to(a, 'utf-8')
  assert_equal "[166417]_Bekr=E6ftelse_fra_Rejsefeber", b
end