Page MenuHomePhabricator

[libcxx] Mark unsupported tests under root user
AbandonedPublic

Authored by twoh on Aug 6 2019, 10:14 AM.

Details

Summary

Some of libcxx unit tests are failing under sudo, as they check the permissions after certain operations but sudo overrides it. Mark these tests unsupported if the test is running under sudo.

Event Timeline

twoh created this revision.Aug 6 2019, 10:14 AM
Herald added a project: Restricted Project. · View Herald TranscriptAug 6 2019, 10:14 AM
Herald added a subscriber: christof. · View Herald Transcript
ldionne requested changes to this revision.Aug 6 2019, 11:19 AM
ldionne added a subscriber: ldionne.

I would suggest not running the tests under sudo.

This revision now requires changes to proceed.Aug 6 2019, 11:19 AM
twoh added a comment.Aug 6 2019, 11:39 AM

I explained it over libcxx-dev mailing list, but our internal build system requires root permission when running the build and test from the remote container. I admit that this is not a common case, but still, wouldn't it be better to make the tests working under any circumstance?

I admit that this is not a common case, but still, wouldn't it be better to make the tests working under any circumstance?

No, because that means we have to maintain that. In this specific case, support for running the tests under root also means that we have to be careful with not messing up your system in irreversible ways in the test suite. And it would mean in theory that we need to add such a testing configuration, otherwise the tests and the annotations will get out of sync and your use case will break again.

We discussed it with other libc++ maintainers and it is our opinion that the use case of running the tests under sudo is not something we want to support at the moment.

twoh abandoned this revision.Aug 6 2019, 11:49 AM

@ldionne Got it. Thank you for your explanation!

@ldionne Got it. Thank you for your explanation!

Sure -- thanks for the patch, and sorry this falls out of scope.