Search in sources :

Example 16 with TagNotFoundException

use of com.android.internal.telephony.uicc.asn1.TagNotFoundException in project android_frameworks_opt_telephony by LineageOS.

the class Asn1NodeTest method testAsBoolean_InvalidData.

@SmallTest
@Test(expected = InvalidAsn1DataException.class)
public void testAsBoolean_InvalidData() throws TagNotFoundException, InvalidAsn1DataException {
    Asn1Node node = Asn1Node.newBuilder(0xBF37).addChildAsString(1, "1").build();
    node.getChild(1).asBoolean();
}
Also used : Asn1Node(com.android.internal.telephony.uicc.asn1.Asn1Node) SmallTest(android.test.suitebuilder.annotation.SmallTest) Test(org.junit.Test) SmallTest(android.test.suitebuilder.annotation.SmallTest)

Aggregations

Asn1Node (com.android.internal.telephony.uicc.asn1.Asn1Node)16 Test (org.junit.Test)14 SmallTest (android.test.suitebuilder.annotation.SmallTest)13 Asn1Decoder (com.android.internal.telephony.uicc.asn1.Asn1Decoder)7 InvalidAsn1DataException (com.android.internal.telephony.uicc.asn1.InvalidAsn1DataException)3 TagNotFoundException (com.android.internal.telephony.uicc.asn1.TagNotFoundException)2 Nullable (android.annotation.Nullable)1 UiccAccessRule (android.telephony.UiccAccessRule)1 TelephonyTest (com.android.internal.telephony.TelephonyTest)1