Skip to content

Commit b73f673

Browse files
amedeeitext-teamcity
authored andcommitted
Restore Unicode characters in Utf8FormsTest.java
RND-486 Autoported commit. Original commit hash: [7a78398aa]
1 parent 0105734 commit b73f673

File tree

3 files changed

+6
-48
lines changed

3 files changed

+6
-48
lines changed

itext.tests/itext.forms.tests/itext/forms/Utf8FormsTest.cs

Lines changed: 4 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -1,45 +1,3 @@
1-
/*
2-
This file is part of the iText (R) project.
3-
Copyright (c) 1998-2017 iText Group NV
4-
Authors: iText Software.
5-
6-
This program is free software; you can redistribute it and/or modify
7-
it under the terms of the GNU Affero General Public License version 3
8-
as published by the Free Software Foundation with the addition of the
9-
following permission added to Section 15 as permitted in Section 7(a):
10-
FOR ANY PART OF THE COVERED WORK IN WHICH THE COPYRIGHT IS OWNED BY
11-
ITEXT GROUP. ITEXT GROUP DISCLAIMS THE WARRANTY OF NON INFRINGEMENT
12-
OF THIRD PARTY RIGHTS
13-
14-
This program is distributed in the hope that it will be useful, but
15-
WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
16-
or FITNESS FOR A PARTICULAR PURPOSE.
17-
See the GNU Affero General Public License for more details.
18-
You should have received a copy of the GNU Affero General Public License
19-
along with this program; if not, see http://www.gnu.org/licenses or write to
20-
the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
21-
Boston, MA, 02110-1301 USA, or download the license from the following URL:
22-
http://itextpdf.com/terms-of-use/
23-
24-
The interactive user interfaces in modified source and object code versions
25-
of this program must display Appropriate Legal Notices, as required under
26-
Section 5 of the GNU Affero General Public License.
27-
28-
In accordance with Section 7(b) of the GNU Affero General Public License,
29-
a covered work must retain the producer line in every PDF that is created
30-
or manipulated using iText.
31-
32-
You can be released from the requirements of the license by purchasing
33-
a commercial license. Buying such a license is mandatory as soon as you
34-
develop commercial activities involving the iText software without
35-
disclosing the source code of your own applications.
36-
These activities include: offering paid services to customers as an ASP,
37-
serving PDFs on the fly in a web application, shipping iText with a closed
38-
source product.
39-
40-
For more information, please contact iText Software Corp. at this
41-
42-
*/
431
using System;
442
using System.Collections.Generic;
453
using iText.Forms.Fields;
@@ -76,7 +34,7 @@ public virtual void ReadUtf8FieldName() {
7634
IDictionary<String, PdfFormField> fields = form.GetFormFields();
7735
pdfDoc.Close();
7836
foreach (String fldName in fields.Keys) {
79-
// ??
37+
// لا
8038
NUnit.Framework.Assert.AreEqual("\u0644\u0627", fldName);
8139
}
8240
pdfDoc.Close();
@@ -92,7 +50,7 @@ public virtual void ReadUtf8TextAnnot() {
9250
IDictionary<String, PdfFormField> fields = form.GetFormFields();
9351
pdfDoc.Close();
9452
foreach (String fldName in fields.Keys) {
95-
// ?? ??UTF8
53+
// 福昕 福昕UTF8
9654
NUnit.Framework.Assert.AreEqual("\u798F\u6615 \u798F\u6615UTF8", fields.Get(fldName).GetValueAsString());
9755
}
9856
}
@@ -105,9 +63,9 @@ public virtual void WriteUtf8FieldNameAndValue() {
10563
PdfAcroForm form = PdfAcroForm.GetAcroForm(pdfDoc, true);
10664
PdfTextFormField field = PdfTextFormField.CreateText(pdfDoc, new Rectangle(99, 753, 425, 15), "", "");
10765
field.SetFont(PdfFontFactory.CreateFont(FONT, PdfEncodings.IDENTITY_H));
108-
// ??
66+
// لا
10967
field.Put(PdfName.T, new PdfString("\u0644\u0627", PdfEncodings.UTF8));
110-
// ?? ??UTF8
68+
// 福昕 福昕UTF8
11169
field.Put(PdfName.V, new PdfString("\u798F\u6615 \u798F\u6615UTF8", PdfEncodings.UTF8));
11270
field.RegenerateField();
11371
form.AddField(field);

itext.tests/itext.io.tests/itext/io/font/FontProgramTest.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ public class FontProgramTest {
5151
/// <exception cref="System.IO.IOException"/>
5252
[NUnit.Framework.Test]
5353
public virtual void ExceptionMessageTest() {
54-
NUnit.Framework.Assert.That(() => {E
54+
NUnit.Framework.Assert.That(() => {
5555
FontProgramFactory.CreateFont(notExistingFont);
5656
}
5757
, NUnit.Framework.Throws.TypeOf<System.IO.IOException>().With.Message.EqualTo(MessageFormatUtil.Format("{0} not found as file or resource", notExistingFont)));

port-hash

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
5eb9eee2052f6ac2930159d89a3d9ba94111b8b1
1+
7a78398aac2d51746d4b3eeff1ad1c9809397563

0 commit comments

Comments
 (0)