summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/wifitests/src/com/android/server/wifi/ClientModeImplTest.java10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/wifitests/src/com/android/server/wifi/ClientModeImplTest.java b/tests/wifitests/src/com/android/server/wifi/ClientModeImplTest.java
index 8f36770e6..3e904af02 100644
--- a/tests/wifitests/src/com/android/server/wifi/ClientModeImplTest.java
+++ b/tests/wifitests/src/com/android/server/wifi/ClientModeImplTest.java
@@ -3853,6 +3853,16 @@ public class ClientModeImplTest extends WifiBaseTest {
}
/**
+ * Verify the MAC address is being randomized at start to prevent leaking the factory MAC.
+ */
+ @Test
+ public void testNoRandomizeMacAddressOnStartIfMacRandomizationNotEnabled() throws Exception {
+ mResources.setBoolean(R.bool.config_wifi_connected_mac_randomization_supported, false);
+ loadComponentsInStaMode();
+ verify(mWifiNative, never()).setMacAddress(anyString(), any());
+ }
+
+ /**
* Verify bugreport will be taken when get IP_REACHABILITY_LOST
*/
@Test