You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Not sure if you consider this an issue or not, but I think some tests should perhaps be guarded by something like #ifdef UNICORN_HAS_ARM since test_ctl is included in the build by default (regardless of what you set for UNICORN_ARCH), but if for example you only have x86 enabled the tests won't work since they rely on having the arm architecture available.
[0/1] Running tests...
Test project E:/Dev/unicorn/build
Start 1: test_x86
1/3 Test #1: test_x86 ......................... Passed 1.65 sec
Start 2: test_mem
2/3 Test #2: test_mem ......................... Passed 0.10 sec
Start 3: test_ctl
3/3 Test #3: test_ctl .........................***Failed 0.06 sec
67% tests passed, 1 tests failed out of 3
Total Test time (real) = 1.81 sec
The following tests FAILED:
3 - test_ctl (Failed)
PS E:\Dev\unicorn\build> .\test_ctl.exe
Test test_uc_ctl_mode... [ OK ]
Test test_uc_ctl_page_size... [ OK ]
Test test_uc_ctl_arch... [ OK ]
Test test_uc_ctl_time_out... [ OK ]
Test test_uc_ctl_exits... [ OK ]
Test test_uc_ctl_tb_cache... [ OK ]
Test test_uc_ctl_change_page_size... [ FAILED ]
test_ctl.c:183: Check __err == UC_ERR_OK... failed
Invalid/unsupported architecture (UC_ERR_ARCH)
test_ctl.c:184: Check __err == UC_ERR_OK... failed
Invalid/unsupported architecture (UC_ERR_ARCH)
Unhandled SEH exception... failed
Exception code: 0xc0000005
Exception address: 0x00007FFB19DC7036
Access violation.
Test test_uc_ctl_arm_cpu... [ FAILED ]
test_ctl.c:201: Check __err == UC_ERR_OK... failed
Invalid/unsupported architecture (UC_ERR_ARCH)
Unhandled SEH exception... failed
Exception code: 0xc0000005
Exception address: 0x00007FFB19DC742D
Access violation.
Test test_uc_hook_cached_uaf... [ OK ]
FAILED: 2 of 9 unit tests have failed.
The same thing applies in reverse to the various mem/ctl tests which rely on x86 architecture, but that's probably a much more common use case (i.e. having x86 enabled vs having x86 disabled) so I'm only pointing out the arm specific tests here, since for one of my use cases I only need x86 and I disable the rest to speed up my CI builds and reduce binary sizes (and I like to run the tests on my dependencies to ensure everything is behaving correctly). That being said fixing the inverse would also be nice to allow running the automatically included tests cleanly if you only enable e.g. aarch64.
Relevant tests (for an x86-only build) which should maybe be guarded are:
test_uc_ctl_change_page_size
test_uc_ctl_arm_cpu
Though, I can understand if this is considered "by design"/"won't fix". Wanted to get your thoughts before I proposed any changes.
The text was updated successfully, but these errors were encountered:
Not sure if you consider this an issue or not, but I think some tests should perhaps be guarded by something like #ifdef UNICORN_HAS_ARM since test_ctl is included in the build by default (regardless of what you set for UNICORN_ARCH), but if for example you only have x86 enabled the tests won't work since they rely on having the arm architecture available.
Steps to reproduce:
Test output:
The same thing applies in reverse to the various mem/ctl tests which rely on x86 architecture, but that's probably a much more common use case (i.e. having x86 enabled vs having x86 disabled) so I'm only pointing out the arm specific tests here, since for one of my use cases I only need x86 and I disable the rest to speed up my CI builds and reduce binary sizes (and I like to run the tests on my dependencies to ensure everything is behaving correctly). That being said fixing the inverse would also be nice to allow running the automatically included tests cleanly if you only enable e.g. aarch64.
Relevant tests (for an x86-only build) which should maybe be guarded are:
test_uc_ctl_change_page_size
test_uc_ctl_arm_cpu
Though, I can understand if this is considered "by design"/"won't fix". Wanted to get your thoughts before I proposed any changes.
The text was updated successfully, but these errors were encountered: