diff options
author | Denis Hsu <denis.hsu@mediatek.com> | 2020-07-21 19:32:36 +0800 |
---|---|---|
committer | android-build-team Robot <android-build-team-robot@google.com> | 2020-07-26 20:55:34 +0000 |
commit | 640d347b31caada0e8c2664b700e1867cebcac05 (patch) | |
tree | 92a62c52dcadf9a3c329c5c22b1b67b4a0def9f7 | |
parent | be38051fdf1dc1e92e934522097a321c9c664d46 (diff) | |
download | platform_cts-640d347b31caada0e8c2664b700e1867cebcac05.tar.gz platform_cts-640d347b31caada0e8c2664b700e1867cebcac05.tar.bz2 platform_cts-640d347b31caada0e8c2664b700e1867cebcac05.zip |
Make sure storages ready before testing AdoptableHostTest
This is timing issue.
The setUp() in AdoptableHostTest would set persist.sys.virtual_disk.
And that will cause StorageManager to "reset" all storages.
If try to run the testcase immediately after setUp(), it will cause testcase
failed because storages are not mounted.
For example, testPrimaryOnSameVolume failed because the primary storage
is not mounted.
Test: atest AdoptableHostTest
Bug: 160561499
Change-Id: Ib98f773f4413e54b34d88b974d4750937bbc7765
(cherry picked from commit 5284be0cb624f4cb920885e70f6b4b870005ac4b)
-rw-r--r-- | hostsidetests/appsecurity/src/android/appsecurity/cts/AdoptableHostTest.java | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/hostsidetests/appsecurity/src/android/appsecurity/cts/AdoptableHostTest.java b/hostsidetests/appsecurity/src/android/appsecurity/cts/AdoptableHostTest.java index 927f9f53955..dd47dd6f715 100644 --- a/hostsidetests/appsecurity/src/android/appsecurity/cts/AdoptableHostTest.java +++ b/hostsidetests/appsecurity/src/android/appsecurity/cts/AdoptableHostTest.java @@ -82,6 +82,8 @@ public class AdoptableHostTest extends BaseHostJUnit4Test { hasVirtualDisk = result.startsWith("disk:"); } assertTrue("Virtual disk is not ready: " + result, hasVirtualDisk); + + waitForVolumeReady(); } } |