Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove full binary test #346

Merged
merged 1 commit into from
Aug 31, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 0 additions & 23 deletions tests/test_spotter.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import os
import unittest

import archinfo

Expand All @@ -8,12 +7,6 @@
from pyvex.lifting import register
from pyvex.lifting.util import GymratLifter, Instruction, Type

try:
import angr
except ImportError:
angr = None


test_location = str(os.path.join(os.path.dirname(os.path.realpath(__file__)), "../../binaries/tests"))


Expand Down Expand Up @@ -104,21 +97,6 @@ class CortexSpotter(GymratLifter):
register(CortexSpotter, "ARMEL")


@unittest.skipIf(angr is None, "angr required")
def test_full_binary():
p = angr.Project(
os.path.join(test_location, "armel", "RTOSDemo.axf.issue_685"),
arch="ARMEL",
auto_load_libs=False,
)
st = p.factory.call_state(0x000013CE + 1)
b = st.block().vex
simgr = p.factory.simulation_manager(st)
simgr.step()
assert b.jumpkind == "Ijk_Sys_syscall"
assert simgr.active[0].regs.ip_at_syscall.args[0] == 0x13FB


def test_tmrs():
arch = archinfo.arch_from_id("ARMEL")
ins = b"\xef\xf3\x08\x82"
Expand All @@ -142,6 +120,5 @@ def test_tmsr():
if __name__ == "__main__":
test_basic()
test_embedded()
test_full_binary()
test_tmrs()
test_tmsr()
Loading