b7a7351767
Our signature mapping treats both e.g. bool and jboolean as "Z", and it is allowed to pass a bool variable as an argument to a function expecting a jboolean. Except for fields and callMethod return values, where we only allowed the JNI primitive types. Fix this by comparing the signatures and size of the type we have with the JNI types that there are explicit functions for. Cast from and to the JNI type in both directions to address narrowing (e.g. jboolean is an unsigned char and converting to bool would be narrowing, even though both are 8bit types). This way we can get boolean fields using getField<bool>, and int fields using getField<int> etc. Change-Id: I2f1ba855ee01423e79ba999dfb9d86f4b98b1402 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io> |
||
---|---|---|
.. | ||
auto | ||
baseline | ||
benchmarks | ||
global | ||
libfuzzer | ||
manual | ||
shared | ||
testserver | ||
CMakeLists.txt | ||
README |
This directory contains autotests and benchmarks based on Qt Test. In order to run the autotests reliably, you need to configure a desktop to match the test environment that these tests are written for. Linux X11: * The user must be logged in to an active desktop; you can't run the autotests without a valid DISPLAY that allows X11 connections. * The tests are run against a KDE3 or KDE4 desktop. * Window manager uses "click to focus", and not "focus follows mouse". Many tests move the mouse cursor around and expect this to not affect focus and activation. * Disable "click to activate", i.e., when a window is opened, the window manager should automatically activate it (give it input focus) and not wait for the user to click the window.