Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 68089c81 authored by Siyamed Sinir's avatar Siyamed Sinir
Browse files

Enable Text core tests

Some of the tests were disabled because of the access permissions. This
CL:
* Removes @Suppress annotations
* Annotates the test classes with related annotations such as @SmallTest
* Removes unused imports
* Replaces android.test.sitebuilder.annotation.SmallTest annotations with
  android.support.test.filters.SmallTest

Bug: 29879498
Change-Id: I9e6e326bc6eaf365d7d5c6d1f7edec35e6957302
parent fcef4a3b
Loading
Loading
Loading
Loading
+2 −5
Original line number Diff line number Diff line
@@ -16,18 +16,15 @@

package android.text;

import static android.text.Layout.Alignment.*;

import android.text.DynamicLayout;

import junit.framework.TestCase;

import static android.text.Layout.Alignment.ALIGN_NORMAL;

/**
 * Tests DynamciLayout updateBlocks method.
 *
 * Requires disabling access checks in the vm since this calls package-private APIs.
 *
 * @Suppress
 */
public class DynamicLayoutBlocksTest extends TestCase {
    private DynamicLayout dl = new DynamicLayout("", new TextPaint(), 0, ALIGN_NORMAL, 0, 0, false);
+4 −1
Original line number Diff line number Diff line
@@ -16,6 +16,8 @@

package android.text;

import android.support.test.filters.SmallTest;

import junit.framework.TestCase;

/**
@@ -23,6 +25,7 @@ import junit.framework.TestCase;
 */
public class PackedIntVectorTest extends TestCase {

    @SmallTest
    public void testBasic() throws Exception {
        for (int width = 0; width < 10; width++) {
            PackedIntVector p = new PackedIntVector(width);
+0 −3
Original line number Diff line number Diff line
@@ -16,9 +16,6 @@

package android.text;

import android.text.Spannable;
import android.text.SpannableStringBuilder;

public class SpannableStringBuilderTest extends SpannableTest {

    protected Spannable newSpannableWithText(String text) {
+0 −3
Original line number Diff line number Diff line
@@ -16,9 +16,6 @@

package android.text;

import android.text.Spannable;
import android.text.SpannableString;

public class SpannableStringTest extends SpannableTest {

    protected Spannable newSpannableWithText(String text) {
+0 −1
Original line number Diff line number Diff line
@@ -19,7 +19,6 @@ package android.text;
import android.test.InstrumentationTestCase;
import android.test.MoreAsserts;
import android.test.suitebuilder.annotation.MediumTest;
import android.text.Spannable;

public abstract class SpannableTest extends InstrumentationTestCase {

Loading