Merge "Exclude some DnsResolverTest tests from some CtsNetTestCasesLatestSdk" into main

This commit is contained in:
Mike Yu
2023-07-26 03:17:08 +00:00
committed by Gerrit Code Review
2 changed files with 25 additions and 0 deletions

View File

@@ -180,6 +180,9 @@
}, },
{ {
"exclude-annotation": "com.android.testutils.ConnectivityModuleTest" "exclude-annotation": "com.android.testutils.ConnectivityModuleTest"
},
{
"exclude-annotation": "com.android.testutils.DnsResolverModuleTest"
} }
] ]
}, },
@@ -195,6 +198,9 @@
}, },
{ {
"exclude-annotation": "androidx.test.filters.RequiresDevice" "exclude-annotation": "androidx.test.filters.RequiresDevice"
},
{
"exclude-annotation": "com.android.testutils.DnsResolverModuleTest"
} }
] ]
}, },

View File

@@ -59,6 +59,7 @@ import androidx.test.runner.AndroidJUnit4;
import com.android.net.module.util.DnsPacket; import com.android.net.module.util.DnsPacket;
import com.android.testutils.DevSdkIgnoreRule; import com.android.testutils.DevSdkIgnoreRule;
import com.android.testutils.DevSdkIgnoreRule.IgnoreUpTo; import com.android.testutils.DevSdkIgnoreRule.IgnoreUpTo;
import com.android.testutils.DnsResolverModuleTest;
import com.android.testutils.SkipPresubmit; import com.android.testutils.SkipPresubmit;
import org.junit.After; import org.junit.After;
@@ -317,51 +318,61 @@ public class DnsResolverTest {
} }
@Test @Test
@DnsResolverModuleTest
public void testRawQuery() throws Exception { public void testRawQuery() throws Exception {
doTestRawQuery(mExecutor); doTestRawQuery(mExecutor);
} }
@Test @Test
@DnsResolverModuleTest
public void testRawQueryInline() throws Exception { public void testRawQueryInline() throws Exception {
doTestRawQuery(mExecutorInline); doTestRawQuery(mExecutorInline);
} }
@Test @Test
@DnsResolverModuleTest
public void testRawQueryBlob() throws Exception { public void testRawQueryBlob() throws Exception {
doTestRawQueryBlob(mExecutor); doTestRawQueryBlob(mExecutor);
} }
@Test @Test
@DnsResolverModuleTest
public void testRawQueryBlobInline() throws Exception { public void testRawQueryBlobInline() throws Exception {
doTestRawQueryBlob(mExecutorInline); doTestRawQueryBlob(mExecutorInline);
} }
@Test @Test
@DnsResolverModuleTest
public void testRawQueryRoot() throws Exception { public void testRawQueryRoot() throws Exception {
doTestRawQueryRoot(mExecutor); doTestRawQueryRoot(mExecutor);
} }
@Test @Test
@DnsResolverModuleTest
public void testRawQueryRootInline() throws Exception { public void testRawQueryRootInline() throws Exception {
doTestRawQueryRoot(mExecutorInline); doTestRawQueryRoot(mExecutorInline);
} }
@Test @Test
@DnsResolverModuleTest
public void testRawQueryNXDomain() throws Exception { public void testRawQueryNXDomain() throws Exception {
doTestRawQueryNXDomain(mExecutor); doTestRawQueryNXDomain(mExecutor);
} }
@Test @Test
@DnsResolverModuleTest
public void testRawQueryNXDomainInline() throws Exception { public void testRawQueryNXDomainInline() throws Exception {
doTestRawQueryNXDomain(mExecutorInline); doTestRawQueryNXDomain(mExecutorInline);
} }
@Test @Test
@DnsResolverModuleTest
public void testRawQueryNXDomainWithPrivateDns() throws Exception { public void testRawQueryNXDomainWithPrivateDns() throws Exception {
doTestRawQueryNXDomainWithPrivateDns(mExecutor); doTestRawQueryNXDomainWithPrivateDns(mExecutor);
} }
@Test @Test
@DnsResolverModuleTest
public void testRawQueryNXDomainInlineWithPrivateDns() throws Exception { public void testRawQueryNXDomainInlineWithPrivateDns() throws Exception {
doTestRawQueryNXDomainWithPrivateDns(mExecutorInline); doTestRawQueryNXDomainWithPrivateDns(mExecutorInline);
} }
@@ -610,41 +621,49 @@ public class DnsResolverTest {
} }
@Test @Test
@DnsResolverModuleTest
public void testQueryForInetAddress() throws Exception { public void testQueryForInetAddress() throws Exception {
doTestQueryForInetAddress(mExecutor); doTestQueryForInetAddress(mExecutor);
} }
@Test @Test
@DnsResolverModuleTest
public void testQueryForInetAddressInline() throws Exception { public void testQueryForInetAddressInline() throws Exception {
doTestQueryForInetAddress(mExecutorInline); doTestQueryForInetAddress(mExecutorInline);
} }
@Test @Test
@DnsResolverModuleTest
public void testQueryForInetAddressIpv4() throws Exception { public void testQueryForInetAddressIpv4() throws Exception {
doTestQueryForInetAddressIpv4(mExecutor); doTestQueryForInetAddressIpv4(mExecutor);
} }
@Test @Test
@DnsResolverModuleTest
public void testQueryForInetAddressIpv4Inline() throws Exception { public void testQueryForInetAddressIpv4Inline() throws Exception {
doTestQueryForInetAddressIpv4(mExecutorInline); doTestQueryForInetAddressIpv4(mExecutorInline);
} }
@Test @Test
@DnsResolverModuleTest
public void testQueryForInetAddressIpv6() throws Exception { public void testQueryForInetAddressIpv6() throws Exception {
doTestQueryForInetAddressIpv6(mExecutor); doTestQueryForInetAddressIpv6(mExecutor);
} }
@Test @Test
@DnsResolverModuleTest
public void testQueryForInetAddressIpv6Inline() throws Exception { public void testQueryForInetAddressIpv6Inline() throws Exception {
doTestQueryForInetAddressIpv6(mExecutorInline); doTestQueryForInetAddressIpv6(mExecutorInline);
} }
@Test @Test
@DnsResolverModuleTest
public void testContinuousQueries() throws Exception { public void testContinuousQueries() throws Exception {
doTestContinuousQueries(mExecutor); doTestContinuousQueries(mExecutor);
} }
@Test @Test
@DnsResolverModuleTest
@SkipPresubmit(reason = "Flaky: b/159762682; add to presubmit after fixing") @SkipPresubmit(reason = "Flaky: b/159762682; add to presubmit after fixing")
public void testContinuousQueriesInline() throws Exception { public void testContinuousQueriesInline() throws Exception {
doTestContinuousQueries(mExecutorInline); doTestContinuousQueries(mExecutorInline);