Răsfoiți Sursa

Don't destroy ManagedStatics in a unit test.

Turns out this is very hostile towards other unit tests running in the
same process, it unregisters all flags.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@304165 91177308-0d34-0410-b5e6-96231b3b80d8
Benjamin Kramer 8 ani în urmă
părinte
comite
bcabbd57dc
1 a modificat fișierele cu 0 adăugiri și 6 ștergeri
  1. 0 6
      unittests/Support/ManagedStatic.cpp

+ 0 - 6
unittests/Support/ManagedStatic.cpp

@@ -78,10 +78,6 @@ TEST(ManagedStaticTest, NestedStatics) {
   *Ms2;
   EXPECT_TRUE(Ms1.isConstructed());
   EXPECT_TRUE(Ms2.isConstructed());
-
-  llvm_shutdown();
-  EXPECT_FALSE(Ms1.isConstructed());
-  EXPECT_FALSE(Ms2.isConstructed());
 }
 } // namespace NestedStatics
 
@@ -94,8 +90,6 @@ void *CustomCreate() {
 static ManagedStatic<int, CustomCreate, std::free> Custom;
 TEST(ManagedStaticTest, CustomCreatorDeletor) {
   EXPECT_EQ(42, *Custom);
-  llvm_shutdown();
-  EXPECT_FALSE(Custom.isConstructed());
 }
 } // namespace CustomCreatorDeletor