mirror of
https://github.com/redmine/redmine.git
synced 2025-11-18 03:00:52 +01:00
PDF: check Japanese general_pdf_encoding is CP932 in unit test.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5712 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
@@ -22,6 +22,7 @@ class PdfTest < ActiveSupport::TestCase
|
|||||||
|
|
||||||
def test_fix_text_encoding_nil
|
def test_fix_text_encoding_nil
|
||||||
set_language_if_valid 'ja'
|
set_language_if_valid 'ja'
|
||||||
|
assert_equal 'CP932', l(:general_pdf_encoding)
|
||||||
pdf = Redmine::Export::PDF::IFPDF.new('ja')
|
pdf = Redmine::Export::PDF::IFPDF.new('ja')
|
||||||
assert pdf
|
assert pdf
|
||||||
assert_equal '', pdf.fix_text_encoding(nil)
|
assert_equal '', pdf.fix_text_encoding(nil)
|
||||||
@@ -29,6 +30,7 @@ class PdfTest < ActiveSupport::TestCase
|
|||||||
|
|
||||||
def test_fix_text_encoding_cannot_convert_ja_cp932
|
def test_fix_text_encoding_cannot_convert_ja_cp932
|
||||||
set_language_if_valid 'ja'
|
set_language_if_valid 'ja'
|
||||||
|
assert_equal 'CP932', l(:general_pdf_encoding)
|
||||||
pdf = Redmine::Export::PDF::IFPDF.new('ja')
|
pdf = Redmine::Export::PDF::IFPDF.new('ja')
|
||||||
assert pdf
|
assert pdf
|
||||||
utf8_txt_1 = "\xe7\x8b\x80\xe6\x85\x8b"
|
utf8_txt_1 = "\xe7\x8b\x80\xe6\x85\x8b"
|
||||||
|
|||||||
Reference in New Issue
Block a user