Commit Graph

14 Commits

Author SHA1 Message Date
Remi NGUYEN VAN
8705df6024 Merge "Re-skip connectivity unit tests before S" am: a9230c1bf7 am: 1f3d8dc5e8
Original change: https://android-review.googlesource.com/c/platform/packages/modules/Connectivity/+/1749684

Change-Id: I5e98952aa6cb7406c16e0e05fadc42d7f69759c0
2021-06-30 08:18:37 +00:00
Remi NGUYEN VAN
154cf1da20 Re-skip connectivity unit tests before S
The tests are packaged together with other tests in a common coverage
suite, so need to be individually annotated so that they are skipped
before S.

They do not need to pass on platforms older than S, because such
platforms will not updated with the code that is tested.

This applies a previous change, this time using DevSdkIgnoreRunner,
as SdkSuppress does not work as expected in branches that have a
codename 2 versions above the SDK version, as is the case in AOSP.

Bug: 187935317
Test: atest ConnectivityCoverageTests on R
      atest FrameworksNetTests on S
Change-Id: I5808d34459a4c19238baf8873afa7cf942828460
2021-06-30 12:00:28 +09:00
Treehugger Robot
1882f0ba95 Merge "Revert "Skip connectivity unit tests before S"" am: b0c9e64d33 am: af5ae307f2
Original change: https://android-review.googlesource.com/c/platform/packages/modules/Connectivity/+/1749498

Change-Id: If3e5470c07f5831e53f26da2503075544da42c0f
2021-06-29 08:57:54 +00:00
Remi NGUYEN VAN
284b3c028c Revert "Skip connectivity unit tests before S"
This reverts commit 05dd1ba540.

Reason for revert: Skips more tests than it should in AOSP
Bug: 192302892

Change-Id: I7c5638d8c1cc626354d240a06af758e1cdd92e94
2021-06-29 01:08:00 +00:00
Remi NGUYEN VAN
190ac1c826 Merge "Skip connectivity unit tests before S" am: ef34fd2e21 am: 7ab2d7440c
Original change: https://android-review.googlesource.com/c/platform/packages/modules/Connectivity/+/1736507

Change-Id: Iac57b340cee656237866fc7fdf7af22600a3d56b
2021-06-25 06:07:18 +00:00
Remi NGUYEN VAN
05dd1ba540 Skip connectivity unit tests before S
The tests are packaged together with other tests in a common coverage
suite, so need to be individually annotated so that they are skipped
before S.

They do not need to pass on platforms older than S, because such
platforms will not updated with the code that is tested.

Bug: 187935317
Test: atest ConnectivityCoverageTests on R
Change-Id: I10da45ae023e7f1e8cd11ec857b84346892a3fa8
2021-06-25 10:10:12 +09:00
Remi NGUYEN VAN
16bbc032c3 Merge "Make tests compatible with mockito-extended" am: ad7108ce34 am: c3d789bff1
Original change: https://android-review.googlesource.com/c/platform/packages/modules/Connectivity/+/1737400

Change-Id: I56fcd6452a072d4d6af2f1e81739be5f7f00670a
2021-06-16 13:56:03 +00:00
Remi NGUYEN VAN
c9c745f2f2 Make tests compatible with mockito-extended
This does not change the mockito library to use mockito-extended in
FrameworksNetTests, but changes the tests so that they would pass if
built against that library.

This is useful to run FrameworksNetTests in a common test suite with
other tests that use mockito-extended, for example a common connectivity
coverage test target.

The change includes increasing the test timeout in
ConnectivityServiceTest, as mockito-extended can have performance impact
(~3 times on hwasan builds). This change does not make tests run slower
in the current FrameworksNetTests suite though.

Bug: 187935317
Test: atest FrameworksNetTests
Change-Id: I61fa371e8957037075a2617a014647ff062207c6
2021-06-16 17:53:08 +09:00
Remi NGUYEN VAN
feffd4df22 Merge "Revert "Use mockito-extended in FrameworksNetTests"" am: a6c06af0fa am: 6f6035a29e
Original change: https://android-review.googlesource.com/c/platform/packages/modules/Connectivity/+/1734372

Change-Id: Ib378623e1eecf63f14bd99e70cc9af00aba1baf5
2021-06-11 01:56:50 +00:00
xingdai
892a0ef152 Revert "Use mockito-extended in FrameworksNetTests"
This reverts commit 98b76cc2ec.

Reason for revert: <INSERT REASONING HERE>

b/190622577

Change-Id: Ief39f82875e6fa885829aea62eed00f2f2e6774e
2021-06-10 21:41:54 +00:00
Remi NGUYEN VAN
bd35a6de07 Merge "Use mockito-extended in FrameworksNetTests" am: 35e6108119 am: 98ea169c22
Original change: https://android-review.googlesource.com/c/platform/packages/modules/Connectivity/+/1727825

Change-Id: I1fe4628d1ade1dfe5c9f950895f74994f14fc150
2021-06-09 09:15:39 +00:00
Remi NGUYEN VAN
98b76cc2ec Use mockito-extended in FrameworksNetTests
This is necessary to mock classes like BatteryStatsManager, which cannot
be used without signature permissions, and to merge the test with other
test suites that use mockito extended.

Bug: 187935317
Test: atest FrameworksNetTests
Change-Id: I5dba65d806c5d06b3ff8f633846edb911a7a44ec
2021-06-08 19:12:09 +09:00
Remi NGUYEN VAN
5ed250d90a Move net unit tests to packages/Connectivity
Move the tests together with packages/Connectivity code, so both can be
moved to packages/modules/Connectivity together.

Also reorganize unit tests in a unit/ directory, as other tests
(integration/, common/ etc.) have been added in tests/net since they
were created. This makes the directory structure consistent.

Test: atest FrameworksNetTests
Bug: 187814163
Merged-In: I254ffd1c08ec058d594b4ea55cbae5505f8497cc

Change-Id: I254ffd1c08ec058d594b4ea55cbae5505f8497cc
2021-05-13 08:30:33 +00:00
Remi NGUYEN VAN
678277cc03 Move net unit tests to packages/Connectivity
Move the tests together with packages/Connectivity code, so both can be
moved to packages/modules/Connectivity together.

Also reorganize unit tests in a unit/ directory, as other tests
(integration/, common/ etc.) have been added in tests/net since they
were created. This makes the directory structure consistent.

Test: atest FrameworksNetTests
Bug: 187814163
Ignore-AOSP-First: needs per-branch move for merge conflicts
Change-Id: I254ffd1c08ec058d594b4ea55cbae5505f8497cc
2021-05-13 05:55:44 +00:00