Commit Graph

568 Commits

Author SHA1 Message Date
Aaron Holden
37698cb72b Move libs/deviceutil to device-side/util
Test: build cts, run unit tests
bug:21762834
Change-Id: Ifd164ced7f040e312e3553f27adf59a648f463ab
2016-12-12 12:27:20 -08:00
Aaron Holden
2bc9c349db Nuke CTS Migration Library, extend CompatibilityBuildHelper
bug: 21762834
Test: cts-tradefed run cts -m CtsAppSecurityHostTestCases
Change-Id: I72296ca84c76e4af2de0249e4cdb57fed3065e07
2016-11-22 18:44:36 -08:00
Julien Desprez
f705bf695e Build CTS out of TF source
Test: make cts dist, run unit tests
Bug: 32819381
Change-Id: I202c2a35e3745a372df8bec4903162d933ae04fb
2016-11-11 12:11:33 +00:00
Chris Manton
013a1810f4 resolve merge conflicts of 89b2b0d to master
Test: Run on Nexus6P
run cts --skip-device-info -m CtsHostsideNetworkTests -t com.android.cts.net.HostsideRestrictBackgroundNetworkTests#testDozeModeMetered_enabledButWhitelistedOnNotificationAction
run cts --skip-device-info -m CtsHostsideNetworkTests -t com.android.cts.net.HostsideRestrictBackgroundNetworkTests#testDozeModeNonMetered_enabledButWhitelistedOnNotificationAction

Change-Id: I63a08f5fd0111e183411324ceb53e66fab254222
2016-11-07 23:27:45 -08:00
Chris Manton
89b2b0d039 Include Wear device idle settings am: a84bb771d1
am: 418581d2aa

Change-Id: Ie5a0640553a9825e41a0ac7defc9564b1beb79e5
2016-11-08 03:53:19 +00:00
Chris Manton
a84bb771d1 Include Wear device idle settings
Certain tests interacting with device idle
must set correctly both the normal and wear
device idle setting space.

Bug: 32183373

Test: Run on wear device and Nexus6P
run cts --skip-device-info -m CtsHostsideNetworkTests -t com.android.cts.net.HostsideRestrictBackgroundNetworkTests#testDozeModeMetered_enabledButWhitelistedOnNotificationAction
run cts --skip-device-info -m CtsHostsideNetworkTests -t com.android.cts.net.HostsideRestrictBackgroundNetworkTests#testDozeModeNonMetered_enabledButWhitelistedOnNotificationAction

Change-Id: I6a53d29021a7d4a257b102a4d3bd5d2cc845c16f
2016-11-07 13:45:48 -08:00
Paul Stewart
9d469d0cee Merge "CtsNetTests: Add a test for b/25624963" am: 9ec7e2127c am: 26fc3c1dd7
am: 1db013fafc

Change-Id: I6b69358098b4bae4a079b5178b04477ca21b8b54
2016-10-19 22:06:00 +00:00
Paul Stewart
1db013fafc Merge "CtsNetTests: Add a test for b/25624963" am: 9ec7e2127c
am: 26fc3c1dd7

Change-Id: I718a3b9891c4323ce0c8a3858bb0162ac9878aa7
2016-10-19 21:57:34 +00:00
Paul Stewart
26fc3c1dd7 Merge "CtsNetTests: Add a test for b/25624963"
am: 9ec7e2127c

Change-Id: I8d9b6e56051b31e9c410b8b7009398df9b4fcaf1
2016-10-19 21:49:30 +00:00
Paul Stewart
22b355560e CtsNetTests: Add a test for b/25624963
Ensure that password is not output in toString() for an enterprise
credential.

Bug: 25624963
Test: Run this CTS test: run cts --module CtsNetTestCases --test android.net.wifi.cts.WifiEnterpriseConfigTest#testEnterpriseConfigDoesNotPrintPassword
Change-Id: I84a62ae5d37aa7d397203f41362dadb8ceba1e62
2016-10-19 10:46:09 -07:00
Nicolas Boichat
b07201442a PacketReflector: Ignore IPv6 flow labels in ICMPv6 test am: 36c0f02d94 am: 516b0616e9 am: fac99e31ce am: 171491fa35 am: 983fbfccec am: d9559a2b24
am: 4074750e69

Change-Id: Id0edf811ee808a3ae85211cd3dc23fb14a9b4eb4
2016-10-17 21:08:38 +00:00
Nicolas Boichat
4074750e69 PacketReflector: Ignore IPv6 flow labels in ICMPv6 test am: 36c0f02d94 am: 516b0616e9 am: fac99e31ce am: 171491fa35 am: 983fbfccec
am: d9559a2b24

Change-Id: I1363706a3bd646cb07043f5dc906ddc315667a0e
2016-10-17 17:43:13 +00:00
Nicolas Boichat
983fbfccec PacketReflector: Ignore IPv6 flow labels in ICMPv6 test am: 36c0f02d94 am: 516b0616e9 am: fac99e31ce
am: 171491fa35

Change-Id: I66ef990f1d3e84590409a546f0b5eff307c32bba
2016-10-17 17:23:12 +00:00
Nicolas Boichat
171491fa35 PacketReflector: Ignore IPv6 flow labels in ICMPv6 test am: 36c0f02d94 am: 516b0616e9
am: fac99e31ce

Change-Id: Ib46e30a62620b942afc54d92b1da62412308095a
2016-10-17 17:10:49 +00:00
Nicolas Boichat
516b0616e9 PacketReflector: Ignore IPv6 flow labels in ICMPv6 test
am: 36c0f02d94

Change-Id: Icc98803ea5d4f52cefb43b40d2dcfbd76de1b464
2016-10-17 05:15:47 +00:00
peter_li
c664a142ff [CTS]It should be more reasonable to control battery saver function from setting DB instead of plugging/unplugging charger for CtsHostsideNetworkTests test case. am: 2ecad8d87d am: ca83ca8472 am: 9e20cad5eb
am: 24c9b794f6

Change-Id: I3bf7f653472978babd2a639cf79cbca2500faf3b
2016-10-13 16:12:22 +00:00
peter_li
24c9b794f6 [CTS]It should be more reasonable to control battery saver function from setting DB instead of plugging/unplugging charger for CtsHostsideNetworkTests test case. am: 2ecad8d87d am: ca83ca8472
am: 9e20cad5eb

Change-Id: Ib41d8d3c39c5eaf256541883ec9462af544ed605
2016-10-13 16:03:54 +00:00
peter_li
dc396795cc [CTS]It should be more reasonable to control battery saver function from setting DB instead of plugging/unplugging charger for CtsHostsideNetworkTests test case. am: 2ecad8d87d am: ca83ca8472
am: 254dfe5017

Change-Id: I5955ae432dfe4fd5f751bcf79d307b556e38ac37
2016-10-13 16:03:47 +00:00
peter_li
9e20cad5eb [CTS]It should be more reasonable to control battery saver function from setting DB instead of plugging/unplugging charger for CtsHostsideNetworkTests test case. am: 2ecad8d87d
am: ca83ca8472

Change-Id: I4a497994d5e6c9f8de979ac9bcf05b6be4ce846c
2016-10-13 15:56:56 +00:00
peter_li
254dfe5017 [CTS]It should be more reasonable to control battery saver function from setting DB instead of plugging/unplugging charger for CtsHostsideNetworkTests test case. am: 2ecad8d87d
am: ca83ca8472

Change-Id: Id254c85d140dd854e095e47c1465b73426053fc5
2016-10-13 15:56:52 +00:00
peter_li
ca83ca8472 [CTS]It should be more reasonable to control battery saver function from setting DB instead of plugging/unplugging charger for CtsHostsideNetworkTests test case.
am: 2ecad8d87d

Change-Id: If9c72d61d403b37ecd398179d5d3b447d252d7dc
2016-10-13 15:49:16 +00:00
Tina Zhou
e7c890f1e5 Merge "[CTS]It should be more reasonable to control battery saver function from setting DB instead of plugging/unplugging charger for “CtsHostsideNetworkTests” test case." into nougat-cts-dev 2016-10-13 15:39:50 +00:00
peter_li
2ecad8d87d [CTS]It should be more reasonable to control battery saver function from setting DB instead of plugging/unplugging charger for “CtsHostsideNetworkTests” test case.
Symptom: It should be more reasonable to control battery saver function from setting DB instead of plugging/unplugging charger for “CtsHostsideNetworkTests” test case.
Root Cause: The test function “setBatterySaverMode” of “CtsHostsideNetworkTests” use command to set setting DB when trying to turn on battery saver. But while trying to turn off battery saver, it only use charger plug-in event. It should be more reasonable to turn off battery saver through similar DB setting as this function did at turning on.
Solution: To control battery saver function from setting DB.
Project:
Note:
Test done by RD:
Futher testing need Q team's support:

Bug: 31897608

Change-Id: Id70ba458e85f98393d7652bb4e79bd182172c60f
2016-10-13 07:36:53 +00:00
Felipe Leme
af7c4201f9 Uses bound service instead of ordered broadcast for IPC.
BUG: 32017623
Test: m -j 32 cts  && cts-tradefed run commandAndExit cts -m CtsHostsideNetworkTests
Change-Id: Ibdb84048b04405f234aa5ad9124eb70e9e592498
2016-10-07 11:18:09 -07:00
Amith Yamasani
0ae586a904 Test to ensure a toast doesn't affect app standby am: 87c10012b4 am: a79fdc6a3e
am: 926802bcaa

Change-Id: I6adbbddbb61d79119d57352d0a6299deb1fea0d7
2016-09-22 06:11:19 +00:00
Amith Yamasani
926802bcaa Test to ensure a toast doesn't affect app standby am: 87c10012b4
am: a79fdc6a3e

Change-Id: Ifc27411d8075cd7174037707f80f4be36e2581a6
2016-09-22 01:33:49 +00:00
Amith Yamasani
87c10012b4 Test to ensure a toast doesn't affect app standby
Put an app in standby, make it show a toast and ensure
that it doesn't come out of standby. This is to test
for a bug fix for the same behavior.

Bug: 31544592
Test: cts-tradefed run commandAndExit cts -m CtsHostsideNetworkTests -t com.android.cts.net.HostsideRestrictBackgroundNetworkTests#testAppIdle_toast
Change-Id: I796ecde8e346c308a27969d873e3ce384414fee3
2016-09-21 12:46:52 -07:00
Amith Yamasani
52891d6d96 Tests for idle parole when charging am: 2855028c8e am: 22fcfb341a
am: 6a24e5df31

Change-Id: I70a480298152988668cce2521f955dfb7071312e
2016-09-20 19:40:17 +00:00
Dan Willemsen
4a0758045c DO NOT MERGE ANYWHERE Actually fix cts in nyc-dev-plus-aosp
I did this manually first, but came up with a much better way that
produced a slightly better result (verified the diffs against the next
branch). Sequence of commands:

 # Checkout the last good commit (right before the first bad merge)
 git checkout aa76e8b6fc8515bfc65d4b75456b74c26ee32f1e^
 # Reset the HEAD pointer to the last bad merge, but not the worktree
 git reset 3c197891b50d9ac5e5016f55551b6dff82f62f33
 # Update the index
 git add -A
 # Apply all the changes that mattered between the above to commits
 git cherry-pick -n 29cb19b774b6e0cb73851feb6877da5e42bba78e
 git cherry-pick -n 0e9d107fcfbd3421b7988a4252a9965896019aba
 git cherry-pick -n f19496887beb974c3bc9df9a57f6214a696417b1
 git cherry-pick -n 939e2b253b798386ce53954626fd8044ecb18db6
 git cherry-pick -n 02f07b5d5994b8345ebc86546e5f66524ac04dac
 # Commit the changes
 git commit
 # Rebase the diffs on top of the latest nyc-dev-plus-aosp, since some
 # changes have been manually applied, there will be a few merge
 # conflicts
 git rebase goog/nyc-dev-plus-aosp

All the SHA-1s above were discovered using a combination of this command
to find the changes actually submitted into nyc-dev-plus-aosp itself:

  git log --oneline --first-parent goog/nyc-dev-plus-aosp

and then to find the original commits (that weren't marked as DO NOT
MERGE ANYWHERE):

  git log --oneline --no-merges --stat aa76e8b..goog/nyc-dev-plus-aosp

Change-Id: Iec12619678cb8d011d2c6df26a34ce26e042b854
2016-09-20 05:56:27 +00:00
Amith Yamasani
6a24e5df31 Tests for idle parole when charging am: 2855028c8e
am: 22fcfb341a

Change-Id: Ie0dbb02f9c06aa2dfd358847aa624f07c1cff28f
2016-09-20 02:23:18 +00:00
Amith Yamasani
2855028c8e Tests for idle parole when charging
Make sure that when switching between idle, paroled
and battery saver, the network availability of the app
is correctly updated.

Bug: 31399882
Test: cts-tradefed run commandAndExit cts -m CtsHostsideNetworkTests -t com.android.cts.net.HostsideRestrictBackgroundNetworkTests#testAppIdleNonMetered_whenCharging
Test: cts-tradefed run commandAndExit cts -m CtsHostsideNetworkTests -t com.android.cts.net.HostsideRestrictBackgroundNetworkTests#testAppIdleMetered_whenCharging
Change-Id: I060a0d5f9c3297430b5b623b389c1afdf6abde87
2016-09-19 13:33:27 -07:00
Stephen Li
0d9ef269a9 Revert "Manually merge commit '9be9d5865ba2584a251642359710c074061dee5e' into nyc-dev"
am: 07f9388e4f

Change-Id: I33126a859f4cf14227f743b74fd965b3a0737e9b
2016-09-14 22:36:57 +00:00
Stephen Li
07f9388e4f Revert "Manually merge commit '9be9d5865ba2584a251642359710c074061dee5e' into nyc-dev"
This reverts commit 253fdc667a.

Change-Id: If8862e289eb6693650713ff819c8b05f65cdeda5
2016-09-14 22:25:06 +00:00
Nicolas Boichat
36c0f02d94 PacketReflector: Ignore IPv6 flow labels in ICMPv6 test
Since Linux kernel 4.2, net.ipv6.auto_flowlabels is set by default, and
therefore the request and reply may have different IPv6 flow label.

Bug: 31444338
Test: On a kernel 4.4 board, run com.android.cts.net.HostsideNetworkTests#testVpn
Test: On a kernel 3.18 board, run echo 1 > /proc/sys/net/ipv6/auto_flowlabels, then
      com.android.cts.net.HostsideNetworkTests#testVpn
Change-Id: I913bbf91574239a24cb32ae908834eb951ea2010
2016-09-13 17:32:40 +08:00
Daniel Xie
9be9d5865b Merge "CameraITS scene5 should be skipped if read_3a is not supported" into nougat-cts-dev 2016-09-09 03:33:03 +00:00
TreeHugger Robot
5e7a4643ae Merge "Restore right number of expected intents." 2016-09-08 19:50:16 +00:00
Felipe Leme
0e42d0c0ad Restore right number of expected intents.
They were changed during a refactoring, which is now finished.

Test: cts-tradefed run commandAndExit cts -m CtsHostsideNetworkTests -t com.android.cts.net.HostsideRestrictBackgroundNetworkTests#testDataSaverMode_enabled

Fixes: 28791717
Change-Id: Ia5e99c0c3d421b7d3b58e11ddde4da222d5f8c15
2016-09-08 11:02:35 -07:00
Ian Rogers
774ce009c2 Fix to CtsHostsideNetworkTestsAidl Java library kind. am: 03ee9869ac am: 2984490109
am: 71ae4905ac

Change-Id: I9c7829dbf1798003294da17dfd8e11ca128bd2f2
2016-09-08 12:03:23 +00:00
Ian Rogers
71ae4905ac Fix to CtsHostsideNetworkTestsAidl Java library kind. am: 03ee9869ac
am: 2984490109

Change-Id: I2892485750d0fb055b20af40a54ea601e9ff5a0e
2016-09-08 11:17:05 +00:00
Ian Rogers
03ee9869ac Fix to CtsHostsideNetworkTestsAidl Java library kind.
Fixes Error Prone build.
Bug: 27723540

(cherry picked from commit ad015ac64d0e510cc040a83b1d545e3a1405b1f7)

Change-Id: I150aefde61615023e86e19645a46e432a0183705
2016-09-08 10:51:30 +01:00
sj.cha
3f230f34b8 Merge "Add some failure comments in VpnTest" am: cf8d6e3253 am: 060aa462cb am: ee2b139f7a
am: 560981b972

Change-Id: I778fe7e00000ad936855b76feacf69a030c92a60
2016-09-08 09:42:08 +00:00
sj.cha
560981b972 Merge "Add some failure comments in VpnTest" am: cf8d6e3253 am: 060aa462cb
am: ee2b139f7a

Change-Id: I225d762890934b8f2355d4a2783cc6d2227a90f3
2016-09-08 09:37:10 +00:00
sj.cha
ee2b139f7a Merge "Add some failure comments in VpnTest" am: cf8d6e3253
am: 060aa462cb

Change-Id: Ifb3c10aa186d99add321102d503007b857eba78e
2016-09-08 09:34:36 +00:00
Treehugger Robot
cf8d6e3253 Merge "Add some failure comments in VpnTest" 2016-09-08 09:24:11 +00:00
Roshan Pius
52e10c01af Merge "CtsNetTests: Fix WifiInfoTest" am: 133d0c3dad am: b75c380c17 am: e1794e1518
am: bb422cf538

Change-Id: I5421bfe72fc174c60d59ebf61995f04caec2f66a
2016-09-07 18:03:57 +00:00
Roshan Pius
bb422cf538 Merge "CtsNetTests: Fix WifiInfoTest" am: 133d0c3dad am: b75c380c17
am: e1794e1518

Change-Id: I55a18563f1ee80cda8064c12cf90092e7945697b
2016-09-07 17:57:57 +00:00
Roshan Pius
e1794e1518 Merge "CtsNetTests: Fix WifiInfoTest" am: 133d0c3dad
am: b75c380c17

Change-Id: I62e56e6c6862eb15e2e86c88b1c3ba6f804291b6
2016-09-07 17:52:09 +00:00
Roshan Pius
f1bb48635d CtsNetTests: Fix WifiInfoTest
According to the public documentation of WifiInfo.getSSID(), the
returned value can be one of the following:
1. Hex digits if the SSID cannot be decoded as UTF-8.
2. String surrounded by double quotes if the SSID can be decoded as
UTF-8.
3. <unknown ssid>, if not connected.

Fix the test to check for all these 3 string values.

BUG: 31272462
TEST: The failing CTS test passes now.
Change-Id: I26e12d28994e3cdb4cd1bd9e999633b327ad5830
2016-09-07 08:56:45 -07:00
TreeHugger Robot
cd198fbef3 Merge "Add CTS tests for LocalSocket read/write timeouts" into nyc-mr1-dev 2016-09-06 21:20:20 +00:00
TreeHugger Robot
31e0b838b7 Merge "Fixed number wrong number of expected intents." 2016-09-03 05:47:46 +00:00