summaryrefslogtreecommitdiff
path: root/tests/src
diff options
context:
space:
mode:
authorChiachang Wang <chiachangwang@google.com>2019-05-15 09:52:50 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2019-05-15 09:52:50 +0000
commit54494f95f4e591b479a78efe6aa0e0dcd86ab1cc (patch)
treec3ce598d3705caa939505e2858f10512d447dadc /tests/src
parent6ee95f00c2eff5a46421430e01ed8ec8e0273ce4 (diff)
parentc11639deb0fd3342b43ebd1ac55407b8013d4930 (diff)
Merge "Fix a bug where private DNS to v4-only servers don't validate."
Diffstat (limited to 'tests/src')
-rw-r--r--tests/src/com/android/server/connectivity/NetworkMonitorTest.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/src/com/android/server/connectivity/NetworkMonitorTest.java b/tests/src/com/android/server/connectivity/NetworkMonitorTest.java
index abfb9c8..832b712 100644
--- a/tests/src/com/android/server/connectivity/NetworkMonitorTest.java
+++ b/tests/src/com/android/server/connectivity/NetworkMonitorTest.java
@@ -298,8 +298,10 @@ public class NetworkMonitorTest {
setFallbackSpecs(null); // Test with no fallback spec by default
when(mRandom.nextInt()).thenReturn(0);
+ // DNS probe timeout should not be defined more than half of HANDLER_TIMEOUT_MS. Otherwise,
+ // it will fail the test because of timeout expired for querying AAAA and A sequentially.
when(mResources.getInteger(eq(R.integer.config_captive_portal_dns_probe_timeout)))
- .thenReturn(500);
+ .thenReturn(200);
doAnswer((invocation) -> {
URL url = invocation.getArgument(0);