[llvm] [NFC][ADT] Introduce a test harness for StringRefTest (PR #105500)

Rahul Joshi via llvm-commits llvm-commits at lists.llvm.org
Wed Aug 21 04:46:58 PDT 2024


================
@@ -47,37 +34,39 @@ static_assert(std::is_assignable_v<StringRef &, const char *&&>,
 static_assert(std::is_assignable_v<StringRef &, const char *&>,
               "Assigning from lvalue C string");
 
-namespace {
-TEST(StringRefTest, Construction) {
+// Test fixture.
+class StringRefTest : public testing::Test {};
----------------
jurahul wrote:

Because that will come when I add test cases for reverse iterators, in a follow-on change. I assume I should not be rolling in this change into that. And I see other tests, like StringSetTest using a harness without any members.

https://github.com/llvm/llvm-project/pull/105500


More information about the llvm-commits mailing list