(self)
| 26 | del ql |
| 27 | |
| 28 | def test_riscv64_hello_linux(self): |
| 29 | stdout = SimpleOutStream(1) |
| 30 | ql = Qiling(['../examples/rootfs/riscv64_linux/bin/hello'], '../examples/rootfs/riscv64_linux/', |
| 31 | verbose=QL_VERBOSE.DEFAULT) |
| 32 | |
| 33 | def close(ql, fd): |
| 34 | return 0 |
| 35 | ql.os.set_syscall("close", close, QL_INTERCEPT.CALL) |
| 36 | ql.os.stdout = stdout |
| 37 | ql.run() |
| 38 | self.assertTrue(stdout.read() == b'Hello, World!\n') |
| 39 | |
| 40 | del ql |
| 41 | |
| 42 | def test_riscv64_hello_dyn_linux(self): |
| 43 | stdout = SimpleOutStream(1) |
nothing calls this directly
no test coverage detected