DO NOT MERGE: CDD Annotations for Section: 7.4.2

C-1-1: MUST implement the WifiAwareManager APIs as described in the SDK documentation.
--> SingleDeviceTest

C-1-4:MUST randomize the Wi-Fi Aware management interface address at intervals no longer
then 30 minutes and whenever Wi-Fi Aware is enabled
-->SingleDeviceTest#testAttachDiscoveryAddressChanges()

CDD SECTION:7.4.1.1/C-1-1,C-1-3: Wifi Direct
 C-1-1: MUST implement the corresponding Android API as described in the SDK documentation.
 C-1-3: MUST support regular Wi-Fi operation.
--> ConcurrencyTest

7.4.2.4/C-1-1,C-2-1:
C-1-1: MUST implement the Passpoint related WifiManager APIs as described in the SDK documentation.
C-1-2: MUST support IEEE 802.11u standard, specifically related to Network Discovery and Selection,
such as Generic Advertisement Service (GAS) and Access Network Query Protocol (ANQP).
--> Passpoint configuration tests

Added C-0-3 to ConnectivityBackgroundTestActivity as well

CDD VERSION: 8.1: https://source.android.com/compatibility/8.1/android-8.1-cdd

Bug: 112612833

Test: make cts

Change-Id: Ief11b3ae7899bfdca12a7cce63daca600b1f0cdf
This commit is contained in:
saurav subedi
2018-08-23 13:00:15 -07:00
committed by Saurav Subedi
parent 497a93647c
commit 54fb25689c
6 changed files with 20 additions and 0 deletions

View File

@@ -41,6 +41,8 @@ import android.provider.Settings;
import android.test.AndroidTestCase;
import android.util.Log;
import com.android.compatibility.common.util.CddTest;
import java.util.ArrayDeque;
import java.util.ArrayList;
import java.util.HashSet;
@@ -54,6 +56,7 @@ import java.util.concurrent.TimeUnit;
* Wi-Fi Aware CTS test suite: single device testing. Performs tests on a single
* device to validate Wi-Fi Aware.
*/
@CddTest(requirement="7.4.2.3/C-1-1")
public class SingleDeviceTest extends AndroidTestCase {
private static final String TAG = "WifiAwareCtsTests";
@@ -485,6 +488,7 @@ public class SingleDeviceTest extends AndroidTestCase {
* then the attach/destroy will not correspond to enable/disable and will not result in a new
* MAC address being generated.
*/
@CddTest(requirement="7.4.2.3/C-1-4")
public void testAttachDiscoveryAddressChanges() {
if (!TestUtils.shouldTestWifiAware(getContext())) {
return;

View File

@@ -31,9 +31,12 @@ import static android.net.wifi.p2p.WifiP2pManager.WIFI_P2P_STATE_DISABLED;
import static android.net.wifi.p2p.WifiP2pManager.WIFI_P2P_STATE_ENABLED;
import android.test.AndroidTestCase;
import com.android.compatibility.common.util.CddTest;
import java.util.concurrent.CountDownLatch;
import java.util.concurrent.TimeUnit;
@CddTest(requirement="7.4.2.1/C-1-1,C-1-3")
public class ConcurrencyTest extends AndroidTestCase {
private class MySync {
int expectedWifiState;

View File

@@ -23,6 +23,9 @@ import android.net.wifi.WifiConfiguration;
import android.net.wifi.WifiManager;
import android.test.AndroidTestCase;
import com.android.compatibility.common.util.CddTest;
@CddTest(requirement="7.4.2/C-1-1")
public class WifiConfigurationTest extends AndroidTestCase {
private WifiManager mWifiManager;
@Override

View File

@@ -29,9 +29,11 @@ import android.net.wifi.WifiSsid;
import android.test.AndroidTestCase;
import com.android.compatibility.common.util.PollingCheck;
import com.android.compatibility.common.util.CddTest;
import java.util.concurrent.Callable;
@CddTest(requirement="7.4.2/C-1-1")
public class WifiInfoTest extends AndroidTestCase {
private static class MySync {
int expectedState = STATE_NULL;

View File

@@ -37,6 +37,7 @@ import android.provider.Settings;
import android.test.AndroidTestCase;
import android.util.Log;
import com.android.compatibility.common.util.CddTest;
import com.android.compatibility.common.util.WifiConfigCreator;
import java.net.HttpURLConnection;
@@ -49,6 +50,7 @@ import java.util.Set;
import java.util.concurrent.TimeUnit;
import java.util.concurrent.atomic.AtomicInteger;
@CddTest(requirement="7.4.2/C-1-1")
public class WifiManagerTest extends AndroidTestCase {
private static class MySync {
int expectedState = STATE_NULL;
@@ -586,6 +588,7 @@ public class WifiManagerTest extends AndroidTestCase {
*
* @throws Exception
*/
@CddTest(requirement="7.4.2.4/C-1-1,C-1-2,C-2-1")
public void testAddPasspointConfigWithUserCredential() throws Exception {
if (!WifiFeature.isWifiSupported(getContext())) {
// skip the test if WiFi is not supported
@@ -600,6 +603,7 @@ public class WifiManagerTest extends AndroidTestCase {
*
* @throws Exception
*/
@CddTest(requirement="7.4.2.4/C-1-1,C-1-2,C-2-1")
public void testAddPasspointConfigWithCertCredential() throws Exception {
if (!WifiFeature.isWifiSupported(getContext())) {
// skip the test if WiFi is not supported
@@ -614,6 +618,7 @@ public class WifiManagerTest extends AndroidTestCase {
*
* @throws Exception
*/
@CddTest(requirement="7.4.2.4/C-1-1,C-1-2,C-2-1")
public void testAddPasspointConfigWithSimCredential() throws Exception {
if (!WifiFeature.isWifiSupported(getContext())) {
// skip the test if WiFi is not supported

View File

@@ -21,6 +21,9 @@ import android.net.wifi.WifiManager;
import android.net.wifi.WifiManager.WifiLock;
import android.test.AndroidTestCase;
import com.android.compatibility.common.util.CddTest;
@CddTest(requirement="7.4.2/C-1-1")
public class WifiManager_WifiLockTest extends AndroidTestCase {
private static final String WIFI_TAG = "WifiManager_WifiLockTest";