12
12
import static org .junit .jupiter .api .Assertions .assertEquals ;
13
13
14
14
public class DefaultTexParserTest {
15
-
16
15
private final static String DARWIN = "Darwin1888" ;
17
16
private final static String EINSTEIN = "Einstein1920" ;
18
17
private final static String NEWTON = "Newton1999" ;
@@ -89,9 +88,7 @@ public void testFileEncodingIso88591() throws URISyntaxException {
89
88
TexParserResult expectedParserResult = new TexParserResult ();
90
89
91
90
expectedParserResult .getFileList ().add (texFile );
92
- // The character � is on purpose - we cannot use Apache Tika's CharsetDetector - see ADR-0005
93
- expectedParserResult
94
- .addKey ("anykey" , texFile , 1 , 32 , 45 , "Danach wir anschlie�end mittels \\ cite{anykey}." );
91
+ expectedParserResult .addKey ("anykey" , texFile , 1 , 32 , 45 , "Danach wir anschließend mittels \\ cite{anykey}." );
95
92
96
93
assertEquals (expectedParserResult , parserResult );
97
94
}
@@ -104,9 +101,7 @@ public void testFileEncodingIso885915() throws URISyntaxException {
104
101
TexParserResult expectedParserResult = new TexParserResult ();
105
102
106
103
expectedParserResult .getFileList ().add (texFile );
107
- // The character � is on purpose - we cannot use Apache Tika's CharsetDetector - see ADR-0005
108
- expectedParserResult
109
- .addKey ("anykey" , texFile , 1 , 32 , 45 , "Danach wir anschlie�end mittels \\ cite{anykey}." );
104
+ expectedParserResult .addKey ("anykey" , texFile , 1 , 32 , 45 , "Danach wir anschließend mittels \\ cite{anykey}." );
110
105
111
106
assertEquals (expectedParserResult , parserResult );
112
107
}
@@ -117,17 +112,13 @@ public void testFileEncodingForThreeFiles() throws URISyntaxException {
117
112
Path texFile2 = Paths .get (DefaultTexParserTest .class .getResource ("iso-8859-1.tex" ).toURI ());
118
113
Path texFile3 = Paths .get (DefaultTexParserTest .class .getResource ("iso-8859-15.tex" ).toURI ());
119
114
120
- TexParserResult parserResult = new DefaultTexParser ()
121
- .parse (Arrays .asList (texFile , texFile2 , texFile3 ));
115
+ TexParserResult parserResult = new DefaultTexParser ().parse (Arrays .asList (texFile , texFile2 , texFile3 ));
122
116
TexParserResult expectedParserResult = new TexParserResult ();
123
117
124
118
expectedParserResult .getFileList ().addAll (Arrays .asList (texFile , texFile2 , texFile3 ));
125
- expectedParserResult
126
- .addKey ("anykey" , texFile , 1 , 32 , 45 , "Danach wir anschließend mittels \\ cite{anykey}." );
127
- expectedParserResult
128
- .addKey ("anykey" , texFile2 , 1 , 32 , 45 , "Danach wir anschlie�end mittels \\ cite{anykey}." );
129
- expectedParserResult
130
- .addKey ("anykey" , texFile3 , 1 , 32 , 45 , "Danach wir anschlie�end mittels \\ cite{anykey}." );
119
+ expectedParserResult .addKey ("anykey" , texFile , 1 , 32 , 45 , "Danach wir anschließend mittels \\ cite{anykey}." );
120
+ expectedParserResult .addKey ("anykey" , texFile2 , 1 , 32 , 45 , "Danach wir anschließend mittels \\ cite{anykey}." );
121
+ expectedParserResult .addKey ("anykey" , texFile3 , 1 , 32 , 45 , "Danach wir anschließend mittels \\ cite{anykey}." );
131
122
132
123
assertEquals (expectedParserResult , parserResult );
133
124
}
0 commit comments