-
-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Reduce errors in ICU4J Collator executor results (#185)
* Fix parsing for Collator for ICU4J executor * Refactor ICU4J executor run configs * Add tests for the ICU4J executor for collator * Update ICU4J executor code for Collator to directly call the superclass method * Ensure that ICU4J runs Collator with normalization turned on * Remove unit test based on upstream test data gen bug re: double escaping
- Loading branch information
Showing
3 changed files
with
42 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
33 changes: 33 additions & 0 deletions
33
.../icu4j/73/executor-icu4j/src/test/java/org/unicode/conformance/collator/CollatorTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
package org.unicode.conformance.collator; | ||
|
||
import static org.junit.Assert.assertTrue; | ||
|
||
import org.junit.Test; | ||
import org.unicode.conformance.testtype.collator.CollatorOutputJson; | ||
import org.unicode.conformance.testtype.collator.CollatorTester; | ||
|
||
public class CollatorTest { | ||
|
||
@Test | ||
public void testIgnorePunctuation() { | ||
String testInput = | ||
"{\"label\":\"0001424\",\"s1\":\" ?\",\"s2\":\" ?\",\"line\":59,\"ignorePunctuation\":true}"; | ||
|
||
CollatorOutputJson output = | ||
(CollatorOutputJson) CollatorTester.INSTANCE.getStructuredOutputFromInputStr(testInput); | ||
|
||
assertTrue(output.result); | ||
} | ||
|
||
@Test | ||
public void testNonEscaped() { | ||
String testInput = | ||
"\t{\"label\":\"0006747\",\"s1\":\"̴?\",\"s2\":\"̴̲\",\"line\":5382,\"ignorePunctuation\":true}"; | ||
|
||
CollatorOutputJson output = | ||
(CollatorOutputJson) CollatorTester.INSTANCE.getStructuredOutputFromInputStr(testInput); | ||
|
||
assertTrue(output.result); | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters