Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[lldb/Test] Fix oversight in ProcessEventDataTest::SetUp (NFC) #83895

Merged
merged 1 commit into from
Mar 4, 2024

Conversation

medismailben
Copy link
Member

This patch addresses an oversight in ProcessEventDataTest::SetUp unittest to ensure the Debugger is initialized properly.

This patch addresses an oversight in `ProcessEventDataTest::SetUp`
unittest to ensure the Debugger is initialized properly.

Signed-off-by: Med Ismail Bennani <ismail@bennani.ma>
@llvmbot
Copy link
Collaborator

llvmbot commented Mar 4, 2024

@llvm/pr-subscribers-lldb

Author: Med Ismail Bennani (medismailben)

Changes

This patch addresses an oversight in ProcessEventDataTest::SetUp unittest to ensure the Debugger is initialized properly.


Full diff: https://github.com/llvm/llvm-project/pull/83895.diff

1 Files Affected:

  • (modified) lldb/unittests/Process/ProcessEventDataTest.cpp (+3)
diff --git a/lldb/unittests/Process/ProcessEventDataTest.cpp b/lldb/unittests/Process/ProcessEventDataTest.cpp
index dd159496cd881d..9905e036a138e8 100644
--- a/lldb/unittests/Process/ProcessEventDataTest.cpp
+++ b/lldb/unittests/Process/ProcessEventDataTest.cpp
@@ -16,6 +16,7 @@
 #include "lldb/Target/Thread.h"
 #include "lldb/Utility/ArchSpec.h"
 #include "lldb/Utility/Event.h"
+#include "TestingSupport/TestUtilities.h"
 #include "gtest/gtest.h"
 
 using namespace lldb_private;
@@ -29,6 +30,8 @@ class ProcessEventDataTest : public ::testing::Test {
     FileSystem::Initialize();
     HostInfo::Initialize();
     PlatformMacOSX::Initialize();
+    std::call_once(TestUtilities::g_debugger_initialize_flag,
+                []() { Debugger::Initialize(nullptr); });
   }
   void TearDown() override {
     PlatformMacOSX::Terminate();

@medismailben medismailben merged commit f32c6b2 into llvm:main Mar 4, 2024
4 checks passed
medismailben added a commit to medismailben/llvm-project that referenced this pull request Mar 4, 2024
…83895)

This patch addresses an oversight in `ProcessEventDataTest::SetUp`
unittest to ensure the Debugger is initialized properly.

Signed-off-by: Med Ismail Bennani <ismail@bennani.ma>
medismailben added a commit to swiftlang/llvm-project that referenced this pull request Mar 4, 2024
[lldb/Test] Fix oversight in ProcessEventDataTest::SetUp (NFC) (llvm#83895)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants