summaryrefslogtreecommitdiffstats
path: root/tests/manual/wasm/qtwasmtestlib
Commit message (Collapse)AuthorAgeFilesLines
* Change license for tests filesLucie Gérard2024-02-043-3/+3
| | | | | | | | | | | | According to QUIP-18 [1], all tests file should be LicenseRef-Qt-Commercial OR GPL-3.0-only [1]: https://contribute.qt-project.org/quips/18 Pick-to: 6.7 Task-number: QTBUG-121787 Change-Id: I9657df5d660820e56c96d511ea49d321c54682e8 Reviewed-by: Christian Ehrlicher <[email protected]>
* Make WASM export names different across modulesMikolaj Boc2023-06-202-6/+8
| | | | | | | | The export name is now ${TARGET_NAME}Entry. This can also be overridden by using QT_WASM_EXPORT_NAME, both in CMake and qmake Change-Id: I59c97ae6e22f0b2720716e9d7eff7b6b13d37ab5 Reviewed-by: Morten Johan Sørvig <[email protected]>
* Use SPDX license identifiersLucie Gérard2022-11-151-49/+2
| | | | | | | | | Amends commit 05fc3aef53348fb58be6308076e000825b704e58. Some files were still missing. Task-number: QTBUG-67283 Change-Id: I78b3cbf31138192805b7e186337c6fda4ac844aa Reviewed-by: Jörg Bornemann <[email protected]>
* wasm: add "skip" support to qtwasmtestlibMorten Sørvig2022-08-173-4/+28
| | | | | | | | | | | We're not looking to skip faulty tests, but there are cases where we would like to indicate that a test function exists but can't run because some precondition is not met. Pick-to: 6.4 Change-Id: Ifaaafcfa7a55beaaf56d8b25fabbe3dc2566350f Reviewed-by: Tor Arne Vestbø <[email protected]> Reviewed-by: Mikołaj Boc <[email protected]>
* Use the local file APIs to save/load files on WASMMikolaj Boc2022-08-121-0/+12
| | | | | | | | | | | | QFileDialog::saveFileContent, QFileDialog::getOpenFileContent are now using local file APIs to access files on any browser that passes a feature check. The feature is thoroughly tested using sinon and a new mock library. Task-number: QTBUG-99611 Change-Id: I3dd27a9d21eb143c71ea7db0563f70ac7db3a3ac Reviewed-by: Tor Arne Vestbø <[email protected]> Reviewed-by: Morten Johan Sørvig <[email protected]>
* wasm: add event loop auto testMorten Sørvig2022-08-082-1/+7
| | | | | | | | | | Add basic tests for timers and event processing, for different use cases such as on the main thread, on a secondary thread, and with asyncify. Pick-to: 6.4 Change-Id: Ie0f82b5de97f639867b1e65dbb0ab8b11db86f85 Reviewed-by: Lorn Potter <[email protected]>
* Enhance the qtwasmtestlib with comparison functions and status reportingMikolaj Boc2022-07-054-83/+131
| | | | | | | | | | Added the functionality to report text statuses from tests, reporting file and line of assertion failures. Refactored the qtwasmtestlib.js for improved stability. Task-number: QTBUG-99611 Change-Id: I717e0cc38ac7f155fe870710f6b5e4bfb81b9317 Reviewed-by: Morten Johan Sørvig <[email protected]>
* wasm: add qtwasmtestlibMorten Johan Sørvig2022-06-294-0/+415
qtwasmtestlib supports writing asynchronous tests for the web platform. Asynchronous test functions differ from normal test functions in that they allow returning from the test function before the test has completed: void TestObject::testTimer() { QTimer::singleShot(100, [](){ completeTestFunction(); // Test pass if we get here }); } Currently one logging backend is supported which writes the results to an html element. See the README file for further documentation. Change-Id: Ia633ad3f41a653e40d6bf35dd09d62a97c608f84 Reviewed-by: Mikołaj Boc <[email protected]> Reviewed-by: Tor Arne Vestbø <[email protected]>