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

Commit 031ac63a authored by Gil Cukierman's avatar Gil Cukierman Committed by Android (Google) Code Review
Browse files

Merge "Fix testInitializationFromDb"

parents 8a1b61b8 41426f90
Loading
Loading
Loading
Loading
+4 −6
Original line number Original line Diff line number Diff line
@@ -24,8 +24,6 @@ import android.database.Cursor;
import android.database.MatrixCursor;
import android.database.MatrixCursor;
import android.test.suitebuilder.annotation.SmallTest;
import android.test.suitebuilder.annotation.SmallTest;


import androidx.test.InstrumentationRegistry;

import com.android.internal.util.HexDump;
import com.android.internal.util.HexDump;


import org.junit.After;
import org.junit.After;
@@ -34,7 +32,7 @@ import org.junit.Test;


import java.util.Arrays;
import java.util.Arrays;


public class InboundSmsTrackerTest {
public class InboundSmsTrackerTest extends TelephonyTest {
    InboundSmsTracker mInboundSmsTracker;
    InboundSmsTracker mInboundSmsTracker;


    private static final byte[] FAKE_PDU = new byte[]{1, 2, 3};
    private static final byte[] FAKE_PDU = new byte[]{1, 2, 3};
@@ -50,7 +48,8 @@ public class InboundSmsTrackerTest {


    @Before
    @Before
    public void setUp() throws Exception {
    public void setUp() throws Exception {
        mInboundSmsTracker = new InboundSmsTracker(InstrumentationRegistry.getContext(),
        super.setUp(getClass().getSimpleName());
        mInboundSmsTracker = new InboundSmsTracker(mContext,
                FAKE_PDU, FAKE_TIMESTAMP, FAKE_DEST_PORT, false,
                FAKE_PDU, FAKE_TIMESTAMP, FAKE_DEST_PORT, false,
                FAKE_ADDRESS, FAKE_DISPLAY_ADDRESS, FAKE_REFERENCE_NUMBER, FAKE_SEQUENCE_NUMBER,
                FAKE_ADDRESS, FAKE_DISPLAY_ADDRESS, FAKE_REFERENCE_NUMBER, FAKE_SEQUENCE_NUMBER,
                FAKE_MESSAGE_COUNT, false, FAKE_MESSAGE_BODY, false /* isClass0 */, FAKE_SUBID,
                FAKE_MESSAGE_COUNT, false, FAKE_MESSAGE_BODY, false /* isClass0 */, FAKE_SUBID,
@@ -108,8 +107,7 @@ public class InboundSmsTrackerTest {
    @SmallTest
    @SmallTest
    public void testInitializationFromDb() {
    public void testInitializationFromDb() {
        Cursor cursor = createFakeCursor();
        Cursor cursor = createFakeCursor();
        mInboundSmsTracker = new InboundSmsTracker(InstrumentationRegistry.getContext(),
        mInboundSmsTracker = new InboundSmsTracker(mContext, cursor, false);
                cursor, false);
        cursor.close();
        cursor.close();
        testInitialization();
        testInitialization();
    }
    }