summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author TreeHugger Robot <treehugger-gerrit@google.com> 2017-06-08 06:53:50 +0000
committer Android (Google) Code Review <android-gerrit@google.com> 2017-06-08 06:53:55 +0000
commitc4defd57ed0d2287add976dea61558a19fc9e7c5 (patch)
tree42df17769d8c4af6ea489bf53b9a356a8201c0b2
parentd781b5ce0e7c557407a420cef2d1efc8ca63a746 (diff)
parentdc4ffc0a0b94c80a47ffb292099beb7001a3bb06 (diff)
Merge "Expect hasGlyph support for text presentation sequences"
-rw-r--r--core/tests/coretests/src/android/graphics/PaintTest.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/core/tests/coretests/src/android/graphics/PaintTest.java b/core/tests/coretests/src/android/graphics/PaintTest.java
index 5811ca0fd266..fd27dca589b0 100644
--- a/core/tests/coretests/src/android/graphics/PaintTest.java
+++ b/core/tests/coretests/src/android/graphics/PaintTest.java
@@ -148,7 +148,10 @@ public class PaintTest extends InstrumentationTestCase {
" U+" + Integer.toHexString(vs) + ")";
final String testString =
codePointsToString(new int[] {testCase.mBaseCodepoint, vs});
- if (testCase.mVariationSelectors.contains(vs)) {
+ if (vs == 0xFE0E // U+FE0E is the text presentation emoji. hasGlyph is expected to
+ // return true for that variation selector if the font has the base
+ // glyph.
+ || testCase.mVariationSelectors.contains(vs)) {
assertTrue(signature + " is expected to be true", p.hasGlyph(testString));
} else {
assertFalse(signature + " is expected to be false", p.hasGlyph(testString));