[llvm] r341574 - Move init code in AArch64SelectionDAGTest to SetUpTestCase (NFC)
Scott Linder via llvm-commits
llvm-commits at lists.llvm.org
Thu Sep 6 11:40:35 PDT 2018
Author: scott.linder
Date: Thu Sep 6 11:40:35 2018
New Revision: 341574
URL: http://llvm.org/viewvc/llvm-project?rev=341574&view=rev
Log:
Move init code in AArch64SelectionDAGTest to SetUpTestCase (NFC)
Modified:
llvm/trunk/unittests/CodeGen/AArch64SelectionDAGTest.cpp
Modified: llvm/trunk/unittests/CodeGen/AArch64SelectionDAGTest.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/unittests/CodeGen/AArch64SelectionDAGTest.cpp?rev=341574&r1=341573&r2=341574&view=diff
==============================================================================
--- llvm/trunk/unittests/CodeGen/AArch64SelectionDAGTest.cpp (original)
+++ llvm/trunk/unittests/CodeGen/AArch64SelectionDAGTest.cpp Thu Sep 6 11:40:35 2018
@@ -22,13 +22,13 @@ using namespace llvm;
namespace {
-void initLLVM() {
- InitializeAllTargets();
- InitializeAllTargetMCs();
-}
-
class AArch64SelectionDAGTest : public testing::Test {
protected:
+ static void SetUpTestCase() {
+ InitializeAllTargets();
+ InitializeAllTargetMCs();
+ }
+
void SetUp() override {
StringRef Assembly = "define void @f() { ret void }";
@@ -160,9 +160,3 @@ TEST_F(AArch64SelectionDAGTest, Simplify
}
} // end anonymous namespace
-
-int main(int argc, char **argv) {
- ::testing::InitGoogleTest(&argc, argv);
- initLLVM();
- return RUN_ALL_TESTS();
-}
More information about the llvm-commits
mailing list