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

Commit 47d93dcb authored by Remi NGUYEN VAN's avatar Remi NGUYEN VAN Committed by Android (Google) Code Review
Browse files

Merge "Use NetworkFactory from frameworks/libs/net."

parents 711f59c6 5d9e643b
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -71,6 +71,7 @@ java_library {
    srcs: [
        ":opt-telephony-common-srcs",
        ":framework-telephony-stack-shared-srcs",
        ":net-utils-telephony-common-srcs",
        "src/java/**/I*.aidl",
        "src/java/**/*.logtags",
    ],
+1 −0
Original line number Diff line number Diff line
rule android.net.NetworkFactory* com.android.internal.telephony.NetworkFactory@1
rule android.os.BasicShellCommandHandler* com.android.internal.telephony.BasicShellCommandHandler@1
rule android.os.RegistrantList* com.android.internal.telephony.RegistrantList@1
rule android.os.Registrant* com.android.internal.telephony.Registrant@1
+4 −5
Original line number Diff line number Diff line
@@ -18,7 +18,6 @@ package com.android.internal.telephony;

import static org.junit.Assert.fail;

import android.net.NetworkFactory;
import android.test.suitebuilder.annotation.SmallTest;

import org.junit.Test;
@@ -28,25 +27,25 @@ public class PhoneFactoryTest {
    @SmallTest
    public void testBeforeMakePhone() {
        try {
            Phone phone = PhoneFactory.getDefaultPhone();
            PhoneFactory.getDefaultPhone();
            fail("Expecting IllegalStateException");
        } catch (IllegalStateException e) {
        }

        try {
            Phone phone = PhoneFactory.getPhone(0);
            PhoneFactory.getPhone(0);
            fail("Expecting IllegalStateException");
        } catch (IllegalStateException e) {
        }

        try {
            Phone[] phone = PhoneFactory.getPhones();
            PhoneFactory.getPhones();
            fail("Expecting IllegalStateException");
        } catch (IllegalStateException e) {
        }

        try {
            NetworkFactory factory = PhoneFactory.getNetworkFactory(0);
            PhoneFactory.getNetworkFactory(0);
            fail("Expecting IllegalStateException");
        } catch (IllegalStateException e) {
        }
+2 −3
Original line number Diff line number Diff line
@@ -16,9 +16,8 @@

package com.android.internal.telephony.dataconnection;

import static android.net.NetworkFactory.CMD_CANCEL_REQUEST;
import static android.net.NetworkFactory.CMD_REQUEST_NETWORK;

import static com.android.internal.telephony.NetworkFactory.CMD_CANCEL_REQUEST;
import static com.android.internal.telephony.NetworkFactory.CMD_REQUEST_NETWORK;
import static com.android.internal.telephony.dataconnection.TelephonyNetworkFactory.EVENT_ACTIVE_PHONE_SWITCH;

import static org.junit.Assert.assertEquals;