| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Make it a regular event to avoid the code
duplication.
Also fix a reference to ObjectDestroyed in
QAccessibleEvent::uniqueId().
Also, when searching for events in QVERIFY_EVENT,
accept an event not at position 0, with a qWarning().
Task-number: QTBUG-138824
Change-Id: Ifb18cf9e6baa5123ca90bca182b471a39920bdaf
Reviewed-by: Volker Hilsheimer <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Even though QCOMPARE compares them as equal, it may be useful to know
what the payload was when comparing to something else. Plus, there are
other uses of QTest::toString() where the payload may be relevant (e.g.,
in the comparisons of QCborValue).
IEEE 754:2019 5.1.2 "External character sequences representing zeros,
infinities, and NaNs" recommends:
> Conversion of a signaling NaN in a supported format to an external
> character sequence should produce a language-defined one of “snan” or
> “nan” or a sequence that is equivalent except for case, with an
> optional preceding sign.
There's no recommendation about how to represent the payload. It just
says "Language standards should provide [...] a suffix that can
represent the payload", but doesn't say what. I'm using parentheses
because that's what GDB does:
(gdb) p snan
$1 = nan(0x4000000000000)
(gdb) p nan
$2 = nan(0x8000000000000)
Note how it prints the is_quiet bit, but this commit does not.
Change-Id: I02bf59be578d389db535fffd9d392f5efec72754
Reviewed-by: Edward Welbourne <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
To do that, we cannot convert to double from float or std::float16,
because the conversion can normalize the output to standard zero or
quiet NaN.
We also need to use signbit() because the comparison is always false
otherwise: -0 is equal to 0 (not less than) and all comparisons on NaN
produce false. Moreover, like fpclassify(), signbit() is guaranteed by
the C standard not to raise an NaN consumption exception.
ISO C23 F.3 paragraph 6:
> The C classification macros fpclassify, iscanonical, isfinite, isinf,
> isnan, isnormal, issignaling, issubnormal, iszero, and signbit provide
> the ISO/IEC 60559 operations indicated in Table F.2 provided their
> arguments are in the format of their semantic type. Then these
> macros raise no floating-point exceptions, even if an argument is a
> signaling NaN.
Change-Id: I384599c59c440f36836afffde93b27fdee7a01a6
Reviewed-by: Edward Welbourne <[email protected]>
|
|
|
|
|
|
|
|
| |
Consumers that try to build reporting based on the data tags need
access to both.
Change-Id: Ic3167e9e096e13d351b3333bc4c29a2a7d7efdc0
Reviewed-by: Edward Welbourne <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The \generatelist command takes an optional argument
that affect how the members are listed, for example,
`classesbymodule` which creates an annotated list of
the classes in a named C++ module.
`groupsbymodule` is not recognized or documented. QDoc
falls back to generating a list of all members of a
group in this case. While the end result is correct,
this relies on an undocumented feature that is likely
to change and break.
Replace these instances with an explicit \annotatedlist
command that produces the same output.
Pick-to: 6.10
Task-number: QTBUG-138901
Change-Id: I5d83c0e54daa1888beebb77d8391ea607b8464ed
Reviewed-by: Paul Wicking <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The a11y test library copies events, there is a case where we send
ObjectDestroyed on an object, as opposed to the expected a11y
interface.
When this happens, the program will crash on a null pointer
read.
The fix is to support these two scenarios:
1) (object == nullptr, m_uniqueId set)
2) (object != nullptr, m_childId set)
For the first case, we no longer have access to the object,
so event->object() will be nullptr. This is a change, and happens
when the event is sent from the various destructors.
For the second case, which happens when the object is still
alive, we set m_object, and QAccessibleEvent::accessibleInterface
will do the correct thing and return the interface, this is also a
change, earlier we would try to access m_uniqueId which was
aliased by childId(-1).
Fixes: QTBUG-138824
Pick-to: 6.10
Change-Id: If8e4f8d0e26c3c5793f876b1c25b0653621af1e9
Reviewed-by: Volker Hilsheimer <[email protected]>
|
|
|
|
|
|
|
|
|
| |
For now the private feature 'doc_snippets' is left as is, and acts
as the default for the build-part.
Change-Id: I37476f5f7aabe741cc5eb87c801ec47578d6b488
Reviewed-by: Alexandru Croitor <[email protected]>
Reviewed-by: Paul Wicking <[email protected]>
|
|
|
|
|
|
|
|
|
|
| |
* Mention benchmarking functionality; link to overview documentation.
* Be more specific in wording; Most of QTest API is not made up
of classes, but functions and macros.
Pick-to: 6.10
Change-Id: I93fcc860ba858ed9f3d7a90a6690fa1d72e07896
Reviewed-by: Paul Wicking <[email protected]>
|
|
|
|
|
|
|
|
| |
We send the event from the accessible cache. This is the only
place we have access to both the interface and the object.
Change-Id: I078d6e082b0c3205bfcb544e94b9736360fea4a3
Reviewed-by: Jan Arve Sæther <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
| |
This makes it easier for readers to find out what this is, in case
they don't know, yet.
Amends d4bb448cddce63e0c6a84a86020fa59dd32b2293.
Pick-to: 6.10 6.9 6.8
Change-Id: If2130512c34f974a45af19099bc1dd13d006e186
Reviewed-by: Edward Welbourne <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This allows users of Qt Test to have control over the default
timeout value without having to explicitly pass it via the
*_WITH_TIMEOUT variants of the macros.
Continues on the work done in 55f163382d36ddf908fc2884f2020a1b92340c10.
[ChangeLog][QtTest] Added QTest::defaultTryTimeout to allow
configuring the default timeout used by the QTRY_* functions.
Task-number: QTBUG-81979
Task-number: QTBUG-138160
Change-Id: I04873fd3cc51e9be19850aa5a7de78f9444a11ee
Reviewed-by: Marc Mutz <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
| |
Save future updaters some confusion due to the file not existing on
the more modern version 3 development branch, where no suitable
single-include form of Catch2 exists. We could probably create one,
but the v2.x branch's single header seems to meet our needs.
Task-number: QTBUG-137802
Change-Id: Ieede7793c0700f836c64f4b2fc98496399b24be5
Reviewed-by: Matthias Rauter <[email protected]>
|
|
|
|
|
|
|
|
|
|
| |
[ChangeLog][QtTest][Third-Party Code] Updated Valgrind support to
v3.25.1; this adds support for RISCV 64-bit Linux.
Pick-to: 6.10 6.9 6.8
Task-number: QTBUG-137802
Change-Id: I242cac4c766df4659c68ff5ba5a3196509f91e4b
Reviewed-by: Øystein Heskestad <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Up to C++17 inclusive, a default-constructed std::atomic object can
only be initialized using std::atomic_init(), _not_ by .store().
While __cpp_lib_atomic_shared_ptr is a C++20 feature, when std::atomic
default construction has been fixed, compilers may implement these
feature in any order, and it's not much work to call the
std::atomic<T>(T) ctor in NSDMI instead of the default constructor, so
do that.
Amends a0303cc7c590ff17fb5b0a5975bff98669e42942.
Pick-to: 6.10 6.9 6.8
Change-Id: Id3148db0049ee4e16509c2bfd78c9f9ee145f269
Reviewed-by: David Faure <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The code load()s the shared `loggers` to iterate over it (or copy from
it) (= read the memory pointed to) and it store()s the shared
`loggers` after intializing it (= writing to the memory pointed to).
So relaxed loads and stores are not sufficient here. Stores must have
release memory order and loads acquire memory order, otherwise the
writes before the store() will not happen-before the reads after the
load(), which is a data race, which is UB. The fact that the pointer
is a shared_ptr doesn't change that.
Amends a0303cc7c590ff17fb5b0a5975bff98669e42942.
Pick-to: 6.10 6.9 6.8
Change-Id: I8f82e5db240efdd414983f5b1cb0e1c1f1861100
Reviewed-by: Tim Blechmann <[email protected]>
Reviewed-by: David Faure <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
It's immutable, as appends happen on a copy, so let the stored type
reflect that. Of course, the initial copy needs to be mutable, so
remove the forced cast to SharedLoggersContainer in addLogger().
Amends a0303cc7c590ff17fb5b0a5975bff98669e42942.
Pick-to: 6.10 6.9 6.8
Change-Id: I7e3ca8f3779b1e8a653899069d34216f83480d7f
Reviewed-by: Tim Blechmann <[email protected]>
Reviewed-by: David Faure <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Up to C++17 inclusive, a default-constructed std::atomic object can
only be initialized using std::atomic_init(), _not_ by .store().
While it's probably not a problem in practice, it's also not much work
to call the std::atomic<T>(T) ctor in the ctor-init-list instead of
the implicit default constructor, followed by a store() in the body of
the ctor, so do that.
Amends a8a38f7caabb90113a229629c6fe463acdecd10f.
Pick-to: 6.10 6.9 6.8 6.5
Change-Id: I9ba953d1bc34fe09326554a65393b8a2deb35328
Reviewed-by: David Faure <[email protected]>
|
|
|
|
|
|
|
|
|
| |
For ignored messages, only string and regex are possible. For messages
to warn about, a null variant is also possible.
Pick-to: 6.10 6.9
Change-Id: I3a1b0ebaf541fb8e26794409feb4c5ef9b61d3c3
Reviewed-by: Thiago Macieira <[email protected]>
|
|
|
|
|
|
| |
Pick-to: 6.10 6.9
Change-Id: I30aefa3dafa0975e53f6a7fb253a37032bb9492a
Reviewed-by: Thiago Macieira <[email protected]>
|
|
|
|
|
|
|
|
|
|
| |
Initially motivated by the fact that both branches of a #if closed a
parenthesis that was opened only once before it. Found two more
instance that could also be tidied up.
Pick-to: 6.10 6.9
Change-Id: I268fb8559d0882540746d65ac53d6eee16f1425b
Reviewed-by: Thiago Macieira <[email protected]>
|
|
|
|
|
|
|
|
|
|
| |
This commit adds a `perf` option description and mentions that the
`tickcounter` options requires a hardware support.
Fixes: QTBUG-134795
Pick-to: 6.10 6.9 6.8
Change-Id: I8462073850b6811508776b40e867e62eb88f78e7
Reviewed-by: Dennis Oberst <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
It's easier to interpret an "SEGV_MAPERR", "FPE_INTDIV", or "ILL_ILLOPC"
rather than "code 1".
Alongside the decoded instruction pointer from the previous commit, we
now get a message like:
Received signal 11 (SIGSEGV), code SEGV_MAPERR, at address 0x00005637dd5c1346, for address 0x0000000000000004
Change-Id: Ic9f54e06fd2956fea3ccfffde7aa7b54167333b7
Reviewed-by: Ahmad Samir <[email protected]>
Reviewed-by: Edward Welbourne <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The comment in the QTRY_IMPL macro definition pertains to the
following using namespace std::chrono_literals, which has nothing to
do with the default timeout of QTRY_ macros, because that is
determined somewhere else. Further, "5 seconds" is not a valid chrono
literal, as "5s" was.
Partially reverts 55f163382d36ddf908fc2884f2020a1b92340c10.
Found in API-review.
Pick-to: 6.10
Change-Id: Ic1242436bf87d7067e3c5240eb2687505e24800f
Reviewed-by: Ahmad Samir <[email protected]>
|
|
|
|
|
|
|
|
|
| |
Particularly for the no-parameter case, which fails on any warning, it
makes no sense to not also fail on a critical.
Pick-to: 6.10 6.9
Change-Id: I36f02a7dfb195616ce68babedbccc61480935fb9
Reviewed-by: Mitch Curtis <[email protected]>
|
|
|
|
|
|
| |
Pick-to: 6.9 6.10
Change-Id: Ie2b6964550ea166def27de311c2b948afba5bf04
Reviewed-by: Volker Hilsheimer <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
| |
This class was never pimpled in Qt 5.
Amends the start of the public history.
Pick-to: 6.10 6.9 6.8 6.5
Change-Id: I5761bb0e8401dd654a885b5edcf821be9e4c2694
Reviewed-by: Ivan Solovev <[email protected]>
Reviewed-by: Edward Welbourne <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Amends commit fddb6fceaa28df2a24f7bdd216792985bf8141d1 - the code in
qtestcrashhandler_unix.cpp is written to compile for WASM, and some
declarations in the _p.h aren't excluded on WASM, so the exclusion of
the .cpp when WASM lacks threads lead to linker errors.
Pick-to: 6.10
Change-Id: Idb941643302ed5a4c084d0fd2b4dfc07a44122e3
Reviewed-by: Morten Johan Sørvig <[email protected]>
Reviewed-by: Thiago Macieira <[email protected]>
Reviewed-by: Piotr Wierciński <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Since 6.10, QDoc is capable of generating links to the declaration in
the source code for each documented C++ API entity in their `Detailed
description`.
Add the required configuration to enable this feature in online
documentation builds.
Change-Id: Iaafabc5aea50a6cd72549bb1c04007bb4de498ca
Reviewed-by: Paul Wicking <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
From the user and machine context provided in the signal handler.
Linux w/ GDB prints:
0x563bb2ab7346 <_ZN11tst_Crashes5crashEv+28>: movl $0x1,(%rax)
FreeBSD w/ LLDB prints:
(lldb) x/i 0x0000319a0ae86996
0x319a0ae86996: c7 40 04 01 00 00 00 other movl $0x1, 0x4(%rax)
macOS w/ LLDB prints (after disabling the check for SIP):
(lldb) x/i 0x00000001054086c8
0x1054086c8: movl $0x1, 0x4(%rax)
Done-With: Samuel Gaist
Done-With: Ivan Solovev
Change-Id: Iac02025b1922b6b4d927fffd3efe210ef51fc759
Reviewed-by: Ahmad Samir <[email protected]>
Reviewed-by: Edward Welbourne <[email protected]>
Reviewed-by: Samuel Gaist <[email protected]>
|
|
|
|
|
|
|
|
| |
This is the infrastructure code, without actually getting the
instruction pointer from the machine context.
Change-Id: Iadd2c78913b2d0177949fffdeafa12e9fc3daf87
Reviewed-by: Edward Welbourne <[email protected]>
|
|
|
|
|
|
|
|
| |
There will be variable options.
Change-Id: Ie633615daeac87e8bd2cfffd962666a85d91d5cd
Reviewed-by: Ahmad Samir <[email protected]>
Reviewed-by: Edward Welbourne <[email protected]>
|
|
|
|
|
|
|
|
|
| |
Extracted from existing code; I'm going to need it for some GDB/LLDB
commands in an upcoming commit.
Change-Id: I7bdb7ef287ecd924df5cfffdc5aa3617540f7756
Reviewed-by: Edward Welbourne <[email protected]>
Reviewed-by: Ahmad Samir <[email protected]>
|
|
|
|
|
|
|
|
|
|
| |
For regular strings, it'll call strlen() for us, removing the need of
our doing it. We just have to remove the one case where we were passing
iovec into it: make asyncSafeToString() return a string_view too.
Change-Id: I7d17e5c4525637df23f1fffd5e5c381632386f49
Reviewed-by: Edward Welbourne <[email protected]>
Reviewed-by: Ahmad Samir <[email protected]>
|
|
|
|
|
|
| |
Change-Id: Ib45e7e913fcc2e00f198fffdcc216e9f74c97e15
Reviewed-by: Tor Arne Vestbø <[email protected]>
Reviewed-by: Edward Welbourne <[email protected]>
|
|
|
|
|
|
|
|
|
| |
It's common between the two implementations, though currently completely
unused on Windows because we don't start debuggers.
Change-Id: I7a42db2db35cf6191693fffd3e4e46d482032630
Reviewed-by: Edward Welbourne <[email protected]>
Reviewed-by: Ahmad Samir <[email protected]>
|
|
|
|
|
|
|
|
| |
This further reduces the size of the header.
Change-Id: I24a16daec8aed5a38e1ffffd812629cc7e7377f7
Reviewed-by: Ahmad Samir <[email protected]>
Reviewed-by: Edward Welbourne <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This declutters the header from code that doesn't need to be there and
is only used in the .cpp anyway. This code used to be in qtestcase.cpp
before commit c0014becca2cd376eadd5c8a0265e5cf47c9aa01, which we now
amend. Additionally, since Windows code doesn't need to be async-safe
anyway, we can simplify it.
I'm also going to need the toHexString() lambda in another place.
Change-Id: Ic9571bac864dfb31564cfffd785e8ab15cab3ae5
Reviewed-by: Edward Welbourne <[email protected]>
Reviewed-by: Ahmad Samir <[email protected]>
|
|
|
|
|
|
|
|
|
| |
It accesses no members (there are none!), which further simplifies the
header.
Change-Id: Ic1251d8b56dc6cfeb136fffd7baf4d8bc7143750
Reviewed-by: Ahmad Samir <[email protected]>
Reviewed-by: Edward Welbourne <[email protected]>
|
|
|
|
|
|
|
|
| |
It doesn't need to be in the header.
Change-Id: I2e80568174e6637c6be0fffde4837ac502f4641a
Reviewed-by: Ahmad Samir <[email protected]>
Reviewed-by: Edward Welbourne <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This file is convoluted and hard to read due to #if all over the place.
Let's split the two very different implementations.
This is the conclusion, which removes the Unix code from the Windows
file and the Windows code from the Unix file.
Drive-by remove the unnecessary header #includes.
Change-Id: Iec7bd36d0aeabdc3c445fffd17bad22050c6b208
Reviewed-by: Edward Welbourne <[email protected]>
Reviewed-by: Ahmad Samir <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
| |
This file is convoluted and hard to read due to #if all over the place.
Let's split the two very different implementations.
This is the first commit, which just copies the files around without any
changes, to help with Git history.
Change-Id: I758dad7a07d927ccb61dfffd0199fb5e1e544c98
Reviewed-by: Edward Welbourne <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Processes usually crash due to invalid pointers, but sometimes it's hard
to know if a given value is valid or not just by eyeballing it. So let's
ask GDB to print it.
I don't think LLDB has a way to do it.
Pick-to: 6.9
Change-Id: I35e35bd3b79eeba49192fffd61474054cd089301
Reviewed-by: Edward Welbourne <[email protected]>
|
|
|
|
|
|
|
|
|
|
| |
Due to synchronous position handling, it is not necessary to wait for
event based geometry updates.
Always return true on Android.
Change-Id: Iad1da66e38b2ec1193c5569b4d1764c7202ea319
Reviewed-by: Axel Spoerl <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The QTest documentation incorrectly referenced
Qt5Test instead of Qt6Test. This has been updated
to reflect the correct module name.
Fixes outdated references in the documentation and
ensures consistency with Qt 6 naming conventions.
Fixes: QTBUG-134395
Change-Id: I254df83ecbea542c1a47b17aa0b756ed8a6f562a
Reviewed-by: Alexandru Croitor <[email protected]>
|
|
|
|
|
|
|
|
|
|
| |
Move it into a global static, so that we can allow changing it in a
follow-up commit.
Task-number: QTBUG-81979
Change-Id: I795002054f9aa7781157739b94fc2b85bcb61705
Reviewed-by: Thiago Macieira <[email protected]>
Reviewed-by: Edward Welbourne <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Other test loggers just output things immediately, but the junit test
logger appends messages to a vector, so this needs to be
mutex-protected.
In case of qDebug()s from long-running threads, we also need
to protect creation/destruction of systemOutputElement and
systemErrorElement -- and in case of qFatal(), currentTestCase.
Pick-to: 6.9 6.8 6.5
Change-Id: If35055fc232276a778951ebbfeaccd185b04f46b
Reviewed-by: Edward Welbourne <[email protected]>
Reviewed-by: Jason McDonald <[email protected]>
|
|
|
|
|
|
|
|
|
| |
The WatchDog thread calls printTestRunTime() which reads the two
timers, created and started in the main thread.
Pick-to: 6.9 6.8 6.5
Change-Id: I1a337648fddf87190075b7902311544d0ab21ac3
Reviewed-by: Marc Mutz <[email protected]>
|
|
|
|
|
|
|
|
|
|
| |
So future-me and others don't have to look through the source code to
figure it out.
Pick-to: 6.9 6.8 6.5
Change-Id: I1f6e46cec256112226cad4d24ed52e4818635ae8
Reviewed-by: Giuseppe D'Angelo <[email protected]>
Reviewed-by: Thiago Macieira <[email protected]>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Implement ensurePositionTopLeft() to set a window's position
to the available top-left corner and verify that it is correctly
positioned.
Incorrect updates to window.position and window.framePosition have
been identified as one of the main sources of flakiness on
Opensuse. This test function addresses this issue and improves test
reliablity.
Task-number: QTQAINFRA-7050
Change-Id: I946f74c7d2c1db9cfe4fec7db272e12876b3ed43
Reviewed-by: Tor Arne Vestbø <[email protected]>
Reviewed-by: Axel Spoerl <[email protected]>
|
|
|
|
|
|
|
|
|
| |
Adds a missing include for QElapsedTimer.
Pick-to: 6.9 6.8
Change-Id: I3dbc19eb38bb44cae1e38a0c72981a14bc571cd5
Reviewed-by: Thiago Macieira <[email protected]>
Reviewed-by: Marc Mutz <[email protected]>
|