use of com.google.security.zynamics.binnavi.debug.connection.packets.replies.ReadMemoryReply in project binnavi by google.
the class CDebuggerSynchronizerTest method testMemorySucc.
@Test
public void testMemorySucc() {
debuggerSynchronizer.receivedEvent(new ReadMemoryReply(0, 0, CommonTestObjects.BP_ADDRESS_123.getAddress().getAddress(), "Hannes".getBytes()));
assertEquals(0, listener.exception);
assertEquals("RECEIVED_MEMORY/00000123/6;", listener.events);
assertTrue(mockDebugger.getProcessManager().getMemory().hasData(0x123, 6));
}
use of com.google.security.zynamics.binnavi.debug.connection.packets.replies.ReadMemoryReply in project binnavi by google.
the class CDebuggerSynchronizerTest method testMemoryErr.
@Test
public void testMemoryErr() {
debuggerSynchronizer.receivedEvent(new ReadMemoryReply(0, 5, null, null));
assertEquals(0, listener.exception);
assertEquals("ERROR_READING_MEMORY/5;", listener.events);
assertFalse(mockDebugger.getProcessManager().getMemory().hasData(CommonTestObjects.BP_ADDRESS_123.getAddress().getAddress().toLong(), 6));
}
Aggregations