[libcxx-commits] [PATCH] D98127: [libcxx] [test] Clarify and improve consistency in lexically_relative_and_proximate.pass.cpp. NFC.

Martin Storsjö via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Sat Mar 6 12:57:50 PST 2021


mstorsjo created this revision.
mstorsjo requested review of this revision.
Herald added a project: libc++.
Herald added a reviewer: libc++.

Use "expect" instead of "output" for generating "proximate_expected".
pass the arguments to PathEq in the same order as above.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D98127

Files:
  libcxx/test/std/input.output/filesystems/class.path/path.member/path.gen/lexically_relative_and_proximate.pass.cpp


Index: libcxx/test/std/input.output/filesystems/class.path/path.member/path.gen/lexically_relative_and_proximate.pass.cpp
===================================================================
--- libcxx/test/std/input.output/filesystems/class.path/path.member/path.gen/lexically_relative_and_proximate.pass.cpp
+++ libcxx/test/std/input.output/filesystems/class.path/path.member/path.gen/lexically_relative_and_proximate.pass.cpp
@@ -84,9 +84,9 @@
     // [path.gen] lexically_proximate
     // Returns: If the value of lexically_relative(base) is not an empty path,
     // return it. Otherwise return *this.
-    const fs::path proximate_expected = output.native().empty() ? p
-        : output;
-    if (!PathEq(proximate_expected, proximate_output))
+    const fs::path proximate_expected = expect.native().empty() ? p
+        : expect;
+    if (!PathEq(proximate_output, proximate_expected))
       ReportErr("path::lexically_proximate", proximate_output, proximate_expected);
   }
   return Failed;


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D98127.328807.patch
Type: text/x-patch
Size: 1004 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libcxx-commits/attachments/20210306/8c64c27a/attachment-0001.bin>


More information about the libcxx-commits mailing list