QuarantineUnittests fail on devices that don't support xattr (chromecast) |
||
Issue descriptionQuarantineTest.FileCanBeAnnotatedWithNoGUID and QuarantineTest.FileCanBeOpenedForReadAfterAnnotation are failing on Chromecast devices. [ RUN ] QuarantineTest.FileCanBeAnnotatedWithNoGUID [11109:11109:1216/140652.174520:2241299249:ERROR:quarantine_linux.cc(33)] Could not set extended attribute user.xdg.origin.url on file /tmp/.org.chromium.Chromium.8NZPss/foo.class: Operation not supported [11109:11109:1216/140652.174654:2241299378:ERROR:quarantine_linux.cc(33)] Could not set extended attribute user.xdg.referrer.url on file /tmp/.org.chromium.Chromium.8NZPss/foo.class: Operation not supported ../../content/common/quarantine/quarantine_unittest.cc:55: Failure Value of: QuarantineFile(test_file, GURL(kInternetURL), GURL(kInternetReferrerURL), std::string()) Actual: 4-byte object <03-00 00-00> Expected: QuarantineFileResult::OK Which is: 4-byte object <00-00 00-00> [ FAILED ] QuarantineTest.FileCanBeAnnotatedWithNoGUID (1 ms) [ RUN ] QuarantineTest.FileCanBeOpenedForReadAfterAnnotation [11107:11107:1216/140651.650920:2240775649:ERROR:quarantine_linux.cc(33)] Could not set extended attribute user.xdg.origin.url on file /tmp/.org.chromium.Chromium.0IqmEt/foo.class: Operation not supported [11107:11107:1216/140651.651054:2240775777:ERROR:quarantine_linux.cc(33)] Could not set extended attribute user.xdg.referrer.url on file /tmp/.org.chromium.Chromium.0IqmEt/foo.class: Operation not supported ../../content/common/quarantine/quarantine_unittest.cc:38: Failure Value of: QuarantineFile(test_file, GURL(kInternetURL), GURL(kInternetReferrerURL), kTestGUID) Actual: 4-byte object <03-00 00-00> Expected: QuarantineFileResult::OK Which is: 4-byte object <00-00 00-00> [ FAILED ] QuarantineTest.FileCanBeOpenedForReadAfterAnnotation (1 ms) The linux unittests guard the xattr tests with check that is_xattr_supported (https://cs.chromium.org/chromium/src/content/common/quarantine/quarantine_linux_unittest.cc?sq=package:chromium&rcl=1482150271&l=94) Would it make sense to add a platform agnotistic IsQuarantineSupported() function in content/public/common/quarantine.h that can be defined per-platform and used by quarantine_unittests.cc to no-op on tests that xattr is supported on?
,
Jan 6 2017
If we do this for tests, it should be called IsQuarantineSupportedForTesting(), because we wouldn't want to use that for regular code.
,
Jan 6 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/6cfa618ab0a05e919b4f375409e9f27e76d21a87 commit 6cfa618ab0a05e919b4f375409e9f27e76d21a87 Author: mbjorge <mbjorge@chromium.org> Date: Fri Jan 06 23:14:31 2017 [Chromecast] Disable Quarantine tests on chromecast. BUG= 678341 Review-Url: https://codereview.chromium.org/2618083002 Cr-Commit-Position: refs/heads/master@{#442089} [modify] https://crrev.com/6cfa618ab0a05e919b4f375409e9f27e76d21a87/content/test/BUILD.gn
,
Jan 6 2017
See also internal bug b/33702076
,
Jan 11 2017
|
||
►
Sign in to add a comment |
||
Comment 1 by mbjorge@chromium.org
, Jan 6 2017Labels: -Pri-3 OS-Linux Pri-2