qt5base-lts/tests
Marc Mutz f044664c68 QFlatMap: add try_emplace (w/o hint)
QFlatMap, like its public brethren, features the broken Qt-style
insert() behavior (what the STL calls insert_or_assign()), which
makes its insert() unusable for actual STL-style insert() work,
with no replacement except the size-check-and-index-operator trick:

    const auto oldSize = c.size();
    auto &e = c[key];
    if (c.size() != oldSize) {
        // inserted
    }

Even though QFlatMap::insert() appears to return the correct info,
it's useless, because the old value has been assigned over by the
time insert() returns.

Pick-to: 6.3 6.2
Change-Id: If4173c42523a128dfd22ab496dde0089ba73f41c
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2022-01-12 02:03:15 +01:00
..
auto QFlatMap: add try_emplace (w/o hint) 2022-01-12 02:03:15 +01:00
baseline Remove faulty #include from widgets baseline test 2022-01-04 05:53:30 +01:00
benchmarks Fix the benchmark for QList::removeAll() 2021-12-09 03:45:08 +01:00
global
libfuzzer Tests: Use REQUIRED COMPONENTS in find_package(Qt6...) 2021-12-13 14:16:26 +00:00
manual wasm: add secondary thread exec manual test 2022-01-05 21:25:42 +01:00
shared QtBase: replace windows.h with qt_windows.h 2021-11-23 12:53:46 +08:00
testserver Network self-test: make it work with docker/containers 2020-11-17 19:56:06 +01:00
CMakeLists.txt CMake: Refactor optimization flag handling and add optimize_full 2020-10-06 10:07:05 +02:00
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.