[Lldb-commits] [PATCH] D70775: [lldb] Add MockTypeSystem and some basic unit test for CompilerType
Pavel Labath via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Wed Nov 27 02:31:24 PST 2019
labath added a comment.
I think this should go into `TestingSupport/Symbol` (new folder) similar to how NativeProcessUtils.h is in `TestingSupport/Host` (to avoid the basic testing support functionality depending on the whole world).
It's not obvious how you intend to use this class, but instead of defining all methods as llvm_unreachable you could consider mocking them via gmock. This way you wouldn't need to create a separate mock class for each use case, and could instead "program" the mocks via something like `EXPECT_CALL(my_mock, GetNumVirtualBaseClasses(42)).Return(47);`.
Repository:
rLLDB LLDB
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D70775/new/
https://reviews.llvm.org/D70775
More information about the lldb-commits
mailing list