simple_tests with mhook

This commit is contained in:
2017-12-27 19:07:15 +01:00
parent 72af6439a7
commit 72b73ee462
8 changed files with 64 additions and 14 deletions

View File

@@ -2,6 +2,14 @@
class AbstractHookEngine {
private:
const char* name_;
public:
/* boolean for each hook test case, which are set by the hooks */
struct {
bool small_;
bool branch;
bool rip_relative;
};
public:
AbstractHookEngine(const char* name) : name_(name) {
@@ -9,7 +17,10 @@ public:
virtual bool hook_all() = 0;
virtual bool unhook_all() = 0;
virtual bool all_hooked() = 0;
bool all_hooked() {
return small_ && branch && rip_relative;
}
const char* name() {
return name_;