Mock syscall

Match the set of calls and arguments to syscall.
Check return value of Generate