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

Commit 3d57eb0b authored by Treehugger Robot's avatar Treehugger Robot Committed by Gerrit Code Review
Browse files

Merge "Verify duplicate upstream notifications are ignored"

parents ed6d75d5 624bf3d7
Loading
Loading
Loading
Loading
+12 −0
Original line number Diff line number Diff line
@@ -294,6 +294,18 @@ public class TetherInterfaceStateMachineTest {
                IFACE_NAME, mTestedSm, STATE_AVAILABLE, TETHER_ERROR_ENABLE_NAT_ERROR);
    }

    @Test
    public void ignoresDuplicateUpstreamNotifications() throws Exception {
        initTetheredStateMachine(TETHERING_WIFI, UPSTREAM_IFACE);

        verifyNoMoreInteractions(mNMService, mStatsService, mTetherHelper);

        for (int i = 0; i < 5; i++) {
            dispatchTetherConnectionChanged(UPSTREAM_IFACE);
            verifyNoMoreInteractions(mNMService, mStatsService, mTetherHelper);
        }
    }

    /**
     * Send a command to the state machine under test, and run the event loop to idle.
     *