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

Commit 2f6aa133 authored by Hyundo Moon's avatar Hyundo Moon
Browse files

Revert "[MAP] Temporarily catch failure in test"

This reverts commit 87367338.

Bug: 257375445
Test: atest BluetoothInstrumentationTests
Reason for revert: The tests are not flaky anymore
(cherry picked from https://android-review.googlesource.com/q/commit:a5fd48440610185ee229c798e49610bed8589e71)
Merged-In: I175110efe6b126c47377cd607c31f895087db353
Change-Id: I175110efe6b126c47377cd607c31f895087db353
parent 58bf9832
Loading
Loading
Loading
Loading
+1 −8
Original line number Diff line number Diff line
@@ -146,15 +146,8 @@ public class BluetoothMapSmsPduTest {

        byte[] encodedMessageSms = messageSmsToEncode.encode();
        InputStream inputStream = new ByteArrayInputStream(encodedMessageSms);
        BluetoothMapbMessage messageParsed;
        try {
          messageParsed = BluetoothMapbMessage.parse(inputStream,
        BluetoothMapbMessage messageParsed = BluetoothMapbMessage.parse(inputStream,
                BluetoothMapAppParams.CHARSET_NATIVE);
        } catch (IllegalArgumentException e) {
          android.util.Log.e("getSubmitPdus_withTypeCDMA", "Failure: " + e);
          // TODO b/257375445 remove try catch that prevent failure
          return;
        }

        assertThat(messageParsed).isInstanceOf(BluetoothMapbMessageSms.class);
    }
+1 −8
Original line number Diff line number Diff line
@@ -84,15 +84,8 @@ public class BluetoothMapbMessageSmsTest {
        byte[] encodedMessageSms = messageSmsToEncode.encode();
        InputStream inputStream = new ByteArrayInputStream(encodedMessageSms);

        BluetoothMapbMessage messageParsed;
        try {
          messageParsed = BluetoothMapbMessage.parse(inputStream,
        BluetoothMapbMessage messageParsed = BluetoothMapbMessage.parse(inputStream,
                BluetoothMapAppParams.CHARSET_NATIVE);
        } catch (IllegalArgumentException e) {
          android.util.Log.e("encodeToByteArray_thenAddByParsing", "Failure: " + e);
          // TODO b/257375445 remove try catch that prevent failure
          return;
        }
        assertThat(messageParsed).isInstanceOf(BluetoothMapbMessageSms.class);
        BluetoothMapbMessageSms messageSmsParsed = (BluetoothMapbMessageSms) messageParsed;
        assertThat(messageSmsParsed.getSmsBody()).isEqualTo(TEST_MESSAGE);