[libc-commits] [PATCH] D105843: [libc] Add option to run specific tests

Siva Chandra via Phabricator via libc-commits libc-commits at lists.llvm.org
Wed Jul 14 09:17:03 PDT 2021


sivachandra added a comment.

Almost there.



================
Comment at: libc/utils/UnitTest/LibcTest.cpp:184
+    std::cout << "No tests run.\n";
+    if(TestFilter)  {
+      std::cout << "No matching test for " << TestFilter << '\n';
----------------
Please run clang-format for all patches touching c++ code. It will fix errors like this. Also, LLVM style says we shouldn't be using the curly brackets for single statement blocks unless the statement spans multiple lines. So, this if block does not need the curly brackets.


================
Comment at: libc/utils/UnitTest/LibcTest.cpp:186
+      std::cout << "No matching test for " << TestFilter << '\n';
+      return 1;
+    }
----------------
aeubanks wrote:
> I'm tempted to always fail if we didn't run any tests since that seems like it should never happen, any thoughts?
Either way is fine.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D105843/new/

https://reviews.llvm.org/D105843



More information about the libc-commits mailing list