diff options
author | Thanos Makatos <thanos.makatos@nutanix.com> | 2021-02-18 11:16:37 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-02-18 11:16:37 +0000 |
commit | 22a80ef616beaf7ac495698a4219f37efe5635c8 (patch) | |
tree | 5ea58cbaa0123adf48add07aee5b09b26ede0d56 /test/mocks.h | |
parent | 0243c6dd892f5ac0ed9c195034a67d2f1f08cec6 (diff) | |
download | libvfio-user-22a80ef616beaf7ac495698a4219f37efe5635c8.zip libvfio-user-22a80ef616beaf7ac495698a4219f37efe5635c8.tar.gz libvfio-user-22a80ef616beaf7ac495698a4219f37efe5635c8.tar.bz2 |
unit test exec_command and friends w.r.t. migration device state (#346)
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
Reviewed-by: Swapnil Ingle <swapnil.ingle@nutanix.com>
Diffstat (limited to 'test/mocks.h')
-rw-r--r-- | test/mocks.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/test/mocks.h b/test/mocks.h index 06b853c..6f5765b 100644 --- a/test/mocks.h +++ b/test/mocks.h @@ -37,6 +37,9 @@ void patch(void *fn); bool is_patched(void *fn); +bool +__real_cmd_allowed_when_stopped_and_copying(u_int16_t cmd); + int handle_dirty_pages(vfu_ctx_t *vfu_ctx, uint32_t size, struct iovec **iovecs, size_t *nr_iovecs, @@ -69,5 +72,10 @@ __real_free(void *ptr); int __real_process_request(vfu_ctx_t *vfu_ctx); +bool +__real_device_is_stopped_and_copying(struct migration *migration); + +bool +__real_should_exec_command(vfu_ctx_t *vfu_ctx, uint16_t cmd); /* ex: set tabstop=4 shiftwidth=4 softtabstop=4 expandtab: */ |