cros-disks: unittest fails when building with clang. |
|||||||||||
Issue descriptionCC=x86_64-cros-linux-gnu-clang CXX=x86_64-cros-linux-gnu-clang++ FEATURES=test emerge-amd64-generic cros-disks [ RUN ] MountManagerTest.MountSucceededWithGivenMountPath [0909/163346:INFO:mount_manager.cc(171)] Path 'source' is mounted to '/media/removable/test' [0909/163346:INFO:mount_manager.cc(214)] Unmounted '/media/removable/test' ../../../../../../../../../mnt/host/source/src/platform2/cros-disks/mount_manager_unittest.cc:407: Failure Value of: mount_state.is_read_only Actual: false Expected: true terminate called after throwing an instance of 'testing::internal::GoogleTestFailureException' what(): ../../../../../../../../../mnt/host/source/src/platform2/cros-disks/mount_manager_unittest.cc:407: Failure Value of: mount_state.is_read_only Actual: false Expected: true Error: /var/cache/portage/chromeos-base/cros-disks/out/Default/disks_testrunner: failed with signal SIGIOT|SIGABRT(6)
,
Sep 11 2016
there is a CL to fix this issue here: https://chromium-review.googlesource.com/#/c/383011
,
Sep 12 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromiumos/platform2/+/3d44fa8ebfbea1ed7bdca2f9d60c4ecc0bb2afc9 commit 3d44fa8ebfbea1ed7bdca2f9d60c4ecc0bb2afc9 Author: George Burgess IV <gbiv@chromium.org> Date: Thu Sep 08 06:47:21 2016 cros-disks: Move a check above Unmount(). The call to `UnmountAll()` in this test was removing the cache entry for `source_path_`. When we called `GetMountStateFromCache`, it returned false and left `mount_state` untouched, so `mount_state.is_read_only` never got initialized. Moving the cache lookup/check above `UnmountAll()` fixes this issue. This patch also adds `EXPECT_TRUE`s around similar calls to `GetMountStateFromCache`, so we can catch issues like this more easily in the future. BUG= chromium:645501 TEST=Test now passes on oak, rather than being flaky. Change-Id: I86781a435e62cb969388a6fb84ab0e4050a4fb70 Reviewed-on: https://chromium-review.googlesource.com/383011 Commit-Ready: George Burgess <gbiv@chromium.org> Tested-by: George Burgess <gbiv@chromium.org> Reviewed-by: Tatsuhisa Yamaguchi <yamaguchi@chromium.org> Reviewed-by: Mike Frysinger <vapier@chromium.org> [modify] https://crrev.com/3d44fa8ebfbea1ed7bdca2f9d60c4ecc0bb2afc9/cros-disks/mount_manager_unittest.cc
,
Sep 12 2016
,
Oct 7 2016
,
Nov 19 2016
,
Jan 21 2017
,
Mar 4 2017
,
Apr 17 2017
,
May 30 2017
,
Aug 1 2017
,
Aug 3 2017
Closing. Please reopen it if its not fixed. Thanks! |
|||||||||||
►
Sign in to add a comment |
|||||||||||
Comment 1 by llozano@chromium.org
, Sep 11 2016