[Lldb-commits] [PATCH] D49685: LLDB does not respect platform sysroot when loading core on Linux

Eugene Birukov via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Mon Jul 30 13:14:19 PDT 2018


EugeneBi added a comment.

In https://reviews.llvm.org/D49685#1179837, @labath wrote:

> In https://reviews.llvm.org/D49685#1178730, @EugeneBi wrote:
>
> > I looked at the tests - is it all in Python? Not sure I have time to learn a new language... Is there anything in C++?
>
>
> We have unit tests in c++, but it's going to be quite hard to tickle this code path from there.
>
> FWIW, I don't think you really need to *know* python to write a test like this. You should be able to fudge it by cargo-culting some code from existing tests and some basic python examples. I expect the test should be something like:
>
>   # copy core file an .exe into an appropriate directory tree
>   self.runCmd("platform select remote-linux --sysroot '%s'" % sysroot)
>   target = self.dbg.CreateTarget(None)
>   process = target.LoadCode(core)
>   self.assertEquals(1, target.GetNumModules())
>   self.assertEquals(exe, target.GetModuleAtIndex(0).GetFileSpec())
>


I am going on vacation till the end of August and I still have something to do at work. Most likely I will not have a chance to look at it until I am back.


https://reviews.llvm.org/D49685





More information about the lldb-commits mailing list