This is an archive of the discontinued LLVM Phabricator instance.

[libcxx] Don't assume cwd name in std::filesystem tests
ClosedPublic

Authored by broadwaylamb on Feb 10 2020, 11:01 AM.

Details

Summary

In std::filesystem::proximate tests we assume that the current working directory's name
is fs.op.proximate. This is fine when we're running the tests locally.

However, if we're running those tests on a remote machine via SSH, the directory layout may be
different. For example, currently we copy each test executable individually into
a temporary directory on the target board using SCP, so the assumption about the working directory name
doesn't necessarily hold.

This patch is the only thing that is necessary for all libc++ tests to pass when run remotely.

Event Timeline

broadwaylamb created this revision.Feb 10 2020, 11:01 AM

Replace cwd.filename() with curdir

broadwaylamb edited the summary of this revision. (Show Details)Feb 10 2020, 11:32 AM
ldionne accepted this revision.Feb 10 2020, 12:22 PM
This revision is now accepted and ready to land.Feb 10 2020, 12:22 PM

Thanks @ldionne, do I need to wait for anyone else’s approval or I can commit this?

Thanks @ldionne, do I need to wait for anyone else’s approval or I can commit this?

My approval is sufficient (or Marshall, or Eric). Please go ahead and commit. Thanks!

EricWF accepted this revision.Feb 12 2020, 4:55 AM
This revision was automatically updated to reflect the committed changes.