2 from lldbsuite
.test
.lldbtest
import *
3 from lldbsuite
.test
.decorators
import *
4 from lldbsuite
.test
.gdbclientutils
import *
5 from lldbsuite
.test
.lldbgdbclient
import GDBRemoteTestBase
8 class TestqOffsets(GDBRemoteTestBase
):
9 class Responder(MockGDBServerResponder
):
11 return "Text=470000;Data=470000"
14 self
.server
.responder
= TestqOffsets
.Responder()
15 target
= self
.createTarget("qOffsets.yaml")
16 text
= target
.modules
[0].FindSection(".text")
17 self
.assertEqual(text
.GetLoadAddress(target
), lldb
.LLDB_INVALID_ADDRESS
)
19 process
= self
.connect(target
)
20 self
.assertEqual(text
.GetLoadAddress(target
), 0x471000)