summaryrefslogtreecommitdiffstats
path: root/util/wasm
Commit message (Collapse)AuthorAgeFilesLines
* Provide the wasm module correctly to the instantiateWasm callbackMikolaj Boc2022-10-011-1/+1
| | | | | | | | | The second parameter to the onDone callback in istantiateWasm was missing in qwasmjsrunner.js, which prevented the wasm module from working on the threaded qt build. Change-Id: I5d1be7a2e0d8043112f304b4d2530acdaae7b398 Reviewed-by: David Skoland <david.skoland@qt.io>
* Adapt the js batched test runner to emrun interfaceMikolaj Boc2022-09-126-108/+302
| | | | | | | | | | This makes the js batched test runner cooperate with emrun. The runner sends back the output and exit messages to emrun to inform it about the test execution state. The code is based on emrun_postjs.js from the emsdk. Change-Id: I758f2c185797f4000810eb4314423eebc1c5d457 Reviewed-by: David Skoland <david.skoland@qt.io>
* Add error message & format selection capability to batched test runnerMikolaj Boc2022-09-011-20/+37
| | | | | Change-Id: I6686bf951204672c3542148e85e59e14e83e73c4 Reviewed-by: David Skoland <david.skoland@qt.io>
* Implement new features in qt-wasmtestrunnerMikolaj Boc2022-08-311-52/+162
| | | | | | | | | | | | The script is now able to: - kill a test that is not responding after certain timeout - multicast output to files/streams (tee-like, but not only on posix) - forward requested format (xml/txt/etc.) to the test executable - run a batched test from a batch test package - interop with the js batched test runner Change-Id: Ia189d78a078e11b9efd25865c5a0ddc6a62d9b85 Reviewed-by: David Skoland <david.skoland@qt.io>
* Create a driver for running batched tests on WASMMikolaj Boc2022-08-245-0/+478
| | | | | | | | | | | | A driver application has been prepared in js for running batched tests. There is a convenient public API defined for reading the current test status & subscribing to changes thereof. The solution is modular - the module qwasmjsruntime can be used for any wasm instantiation, e.g. in the next iteration of qtloader. Change-Id: I00df88188c46a42f86d431285ca96d60d89b3f05 Pick-to: 6.4 Reviewed-by: David Skoland <david.skoland@qt.io>
* Expose the qtloader object globallyDavid Skoland2022-06-031-12/+20
| | | | | | | | | | | | When testing, we need to query the state of the Qt application, so change the scope of qtloader from inside the init function to global scope. Additionally, adjust the test script accordingly to query and use this state to make good decisions on how to terminate. Change-Id: I6264ba20843716eb87340b160680617b718f6bd9 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* Use SPDX license identifiersLucie Gérard2022-05-162-53/+3
| | | | | | | | | | | | | Replace the current license disclaimer in files by a SPDX-License-Identifier. Files that have to be modified by hand are modified. License files are organized under LICENSES directory. Task-number: QTBUG-67283 Change-Id: Id880c92784c40f3bbde861c0d93f58151c18b9f1 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
* Add WASM testrunnerDavid Skoland2022-03-313-0/+261
| | | | | | | | | Add a python script that allows us to run wasm tests in CI, along with the necessary cmake logic to install the script and execute tests accordingly. Change-Id: I93b95c115538c4e27b2b833405acab8162be2a8a Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* Say hello to qtwasmserverMorten Johan Sørvig2021-12-062-0/+161
Development web server for web applications. Supports http and https. Sets COOP and COEP headers. The web server script supports certificate generation using mkcert (github.com/FiloSottile/mkcert). Briefly, mkcert supports generating server certificates for the current local ip address(es), using a certificate authority which can be installed on devices where the app should run. The COOP and COEP headers are required to enable the SharedArrayBuffer API, which is required for Emscripten’s pthreads implementation. The server serves the current directory on localhost by default. Use the “-a” argument to bind to an additional address, or "--all” to bind to all IPv4 addresses found on local network interfaces. Change the directory by passing it as a positional argument. Task-number: QTBUG-79087 Change-Id: Id0cba649e42af53ed8106e336a77e78398bcf901 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: David Skoland <david.skoland@qt.io>