Account for grapheme cluster when trimming to fit a specific length.

Fixes #10076
This commit is contained in:
Fumiaki Yoshimatsu
2020-10-25 18:13:29 -04:00
committed by Alex Hart
parent da4be5c1cf
commit f06817f00d
4 changed files with 387 additions and 10 deletions

View File

@@ -1,6 +1,11 @@
package org.thoughtcrime.securesms.profiles;
import android.app.Application;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.robolectric.RobolectricTestRunner;
import org.robolectric.annotation.Config;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertFalse;
@@ -8,6 +13,8 @@ import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertSame;
import static org.junit.Assert.assertTrue;
@RunWith(RobolectricTestRunner.class)
@Config(manifest = Config.NONE, application = Application.class)
public final class ProfileNameTest {
@Test