llvm-project/lldb/unittests
Jonas Devlieghere f78fcd6906 [lldb/Test] Rewrite ReproducerInstrumentationTest
The instrumentation unit tests' current implementation uses global
variables to track constructor calls for the instrumented classes during
replay. This is suboptimal because it indirectly relies on how the
reproducer instrumentation is implemented. I found out when adding
support for passive replay and the test broke because we made an extra
(temporary) copy of the instrumented objects.

Additionally, the old approach wasn't very self-explanatory. It took me
a bit of time to understand why we were expecting the number of objects
in the test.

This patch rewrites the test and uses the index-to-object-mapping to
verify the objects created during replay. You can now specify the
expected objects, in order, and whether they should be valid or not. I
find that it makes the tests much easier to understand. More
importantly, this approach is resilient to implementation detail changes
in the instrumentation.
2020-04-10 16:50:44 -07:00
..
API [commands] Support autorepeat in SBCommands 2020-04-08 10:54:14 -07:00
Breakpoint [lldb][NFC] Fix all formatting errors in .cpp file headers 2020-01-24 08:52:55 +01:00
Core [lldb] Disable the new Communication test on windows 2020-04-09 15:19:24 +02:00
DataFormatter [lldb][NFC] Fix all formatting errors in .cpp file headers 2020-01-24 08:52:55 +01:00
Disassembler [lldb/Plugins] Rename lldbPluginDisassemblerLLVM (NFC) 2020-02-17 19:14:01 -08:00
Editline [lldb][NFC] Fix all formatting errors in .cpp file headers 2020-01-24 08:52:55 +01:00
Expression [lldb/DWARF] Fix evaluator crash when accessing empty stack. 2020-03-31 17:44:57 +02:00
Host [lldb/Support] Treat empty FileSpec as an invalid file. 2020-04-03 09:29:22 -07:00
Interpreter Make llvm::StringRef to std::string conversions explicit. 2020-01-28 23:25:25 +01:00
Language [LLDB] CPlusPlusNameParser does not handles templated operator< properly 2020-03-27 14:46:39 -07:00
ObjectFile [lldb][NFC] Fix all formatting errors in .cpp file headers 2020-01-24 08:52:55 +01:00
Platform Remap the target (Xcode) SDK directory to the host SDK directory. 2020-04-06 15:51:30 -07:00
Process [lldb] NFC: Fix trivial typo in comments, documents, and messages 2020-04-07 01:06:16 +09:00
ScriptInterpreter [lldb][NFC] Fix all formatting errors in .cpp file headers 2020-01-24 08:52:55 +01:00
Signals [lldb][NFC] Fix all formatting errors in .cpp file headers 2020-01-24 08:52:55 +01:00
Symbol Preserve the owning module information from DWARF in the synthesized AST 2020-04-09 11:09:44 -07:00
SymbolFile [lldb][NFC] Fix unsigned/signed comparison warning in SymbolFileDWARFTest.cpp 2020-03-12 15:30:11 +01:00
Target [lldb/Target] Support more than 2 symbols in StackFrameRecognizer 2020-03-18 14:15:58 +01:00
TestingSupport Preserve the owning module information from DWARF in the synthesized AST 2020-04-09 11:09:44 -07:00
UnwindAssembly [lldb/Plugins] Rename lldbPluginDisassemblerLLVM (NFC) 2020-02-17 19:14:01 -08:00
Utility [lldb/Test] Rewrite ReproducerInstrumentationTest 2020-04-10 16:50:44 -07:00
debugserver [lldb] NFC: Fix trivial typo in comments, documents, and messages 2020-04-07 01:06:16 +09:00
tools [lldb] Change Communication::SetConnection to take a unique_ptr 2020-04-02 14:42:25 +02:00
CMakeLists.txt [commands] Support autorepeat in SBCommands 2020-04-08 10:54:14 -07:00
gtest_common.h [lldb] Update header guards to be consistent and compliant with LLVM (NFC) 2020-02-17 23:15:40 -08:00