Commit Graph

18 Commits

Author SHA1 Message Date
Jarek Kobus
7c0b831391 TaskTree: Implement TrafficLight example
Import from:
https://github.com/qt/qtscxml/tree/dev/examples/scxml/trafficlight-common
and implement it in terms of TaskTree.
The recipe() corresponds to trafficlight.scxml file and implements
the business logic.

Used components: TimeoutTask and BarrierTask.

Change-Id: Ifc08b947388abed8cfc85ba082aaa0b18da0a1d7
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-01-11 11:36:06 +00:00
Jarek Kobus
5a2df08ae0 TaskTree: Add a new example showing input / output data exchange
This example shows how to separate the business logic of the recipe
from the GUI and how to write a reusable recipe.

It shows how to feed the recipe with the initial data and how to
retrieve the final result from the recipe using onStorageSetup()
and onStorageDone() handlers.

Change-Id: I04c0c0c9bd6cf25ac4e91317e527ad12832e9143
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: hjk <hjk@qt.io>
2023-11-15 10:54:05 +00:00
Marcus Tillmanns
e108726314 Terminal: Add auto test
Auto test macOS terminal script.

Change-Id: Iaab9c31fa94cf16afc02e4e34978d5d10edf5c2d
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2023-11-07 11:42:43 +00:00
Christian Kandeler
fca94a8366 qbs build: Fix manual tests
- Remove dependency on project.withAutotests by adding local
{Qt,Cpp}Application overrides that alias QtcManualTest. This way, the
respective products are a QtcManualTest when inside Qt Creator, while
also working outside the source tree.
- Rename QtcManualtest to QtcManualTest. (The reason QtcAutotest is not
camel-cased is because "autotest" is a single word.)
- Plus some minor clean-ups.

Change-Id: Idd77191f0b433d6d7443c639eebda383ab110082
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-09-20 10:22:21 +00:00
Christian Kandeler
a217fa0c22 qbs build: Clean up testing infrastructure
- Rename ambiguously named "testsEnabled" property to "withPluginTests"
  and fix the wrong uses.
- Move AutotestRunner out of main project file and into tests.qbs.
- Move "withAutotests" property into qtc module. We cannot remove it
  from the main project file just yet, because some manual tests do not
  make use of QtcManualTest at the moment.
- Do not remove the autotests from the project tree if autotests are
  disabled. Instead, just disable the products.

Change-Id: I74a4cc717d9adbe53d37536b2565111e1617115b
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-09-19 13:16:28 +00:00
Jarek Kobus
80326d8743 FileSearch: Remove FileIterator and subclasses
Rename tst_SubDirFileIterator into tst_SubDirFileContainer.

Change-Id: I0907ff93f1d6537d200fdc9f5783cfd2a8eb0aa9
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2023-06-30 09:58:10 +00:00
Jarek Kobus
c17c696c1a Spinner: Add an example
Change-Id: Ie10fcc1aa6e31c663296610391d5453792c46a6f
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2023-06-20 18:48:28 +00:00
Christian Stenger
a81c9b497a Tests: Fix qbs build
Change-Id: Ia4a54bab4208c5cdf1c7ce67f5caab84aa1583ef
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-06-06 11:45:04 +00:00
Jarek Kobus
c3344c740a Tasking: Import imagescaling example
It's an initial copy of the
qtbase/examples/qtconcurrent/imagescaling.

The goal is to implement it using TaskTree and
compare both implementations.

Change-Id: I92953a70a3330ac679823060e75e5f39971ae444
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2023-06-06 08:05:39 +00:00
Jarek Kobus
6f8e5c409f TaskTree: De-utils-ize manual test, rename it to demo
Change-Id: I80a2522f7ba12ee9b63c19d66e514d7047951733
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-06-01 10:53:35 +00:00
Jarek Kobus
686a40d199 SubDirFileIterator: Add manual performance test
Compare the total time spent on iterating a big file tree
with 3 different time iterators:
- Utils::SubDirFileIterator
- manually written iterator using QDir::entryInfoList()
- QDirIterator

The iterator run through about one million files (including
about ~100K directories). The more files above this
number to be iterated over, the bigger the relative time
difference of SubDirFileIterator compared to other iterators.

The number of generated files depends on the running
machine's core number. In my case:

Number of cores: 24
Number of generated files: 898753
Number of generated directories: 112345
Time spent on generating file tree: ~2 seconds
Time spent on iterating using SubDirIterator: ~80 seconds
Time spent on iterating using manual iterator: ~8 seconds
Time spent on iterating using QDirIterator: ~4 seconds
Time spent on removing generated file tree: ~2 seconds

Task-number: QTCREATORBUG-28892
Change-Id: I94d7cf0169a470820dc27f39c9cdb4150eea51c1
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-05-19 07:17:01 +00:00
Jarek Kobus
292e8f510e Add manual test for TaskTree
Change-Id: I92ea4d949729f59d2d1e262ecd38fc3be4f463fe
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-11-18 16:36:59 +00:00
Jarek Kobus
d578b3a7c0 Remove manual test for QtcProcess
It's not clear what this test is going to do and
how to run it. Besides, it's not working at least
for one year already. There is not a big loss, since
it was utilizing QtcProcess::readDataFromProcess() only.

Change-Id: I821cd2755d5889ddc3f772352148d595ca1816c2
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-07-11 08:35:32 +00:00
Marcus Tillmanns
0135c47849 device: Use multiplex script to allow multithread support
Previously the runInShell and outputForRunInShell methods were
exclusively processed single threaded, meaning all calls
were processed sequentially. With the multiplexed
helper script we can now run multiple processes simultaneously.
( see tst_manual_deviceshell )

Additionally the new script allows us to capture both
stdout and stderr from commands which was not possible previously.

Change-Id: I52f4fb46d872dc274edb9c11872d2f6543741b34
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-06-07 09:22:14 +00:00
Jarek Kobus
2856091c75 Get rid of SshRemoteProcess
It's being replaced by QtcProcess with path on device.

Change-Id: I29eb038d1b17151683f86855eb547e47f7f7dea5
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: hjk <hjk@qt.io>
2022-05-09 07:42:13 +00:00
Jarek Kobus
5715d433f4 Get rid of SftpFileSystemModel
It's being replaced with DeviceFileSystemModel.

Change-Id: I062f2a873ecede9755527e8ee7b8b4d578289c4b
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2022-04-08 11:50:15 +00:00
Christian Stenger
b822b3f9e2 Tests: Provide qbs files for some manual tests
Change-Id: I6c5c839dc199379edaf4c43ae4d6a0ed6ebdf751
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2022-02-03 05:27:56 +00:00
Alessandro Portale
dce06016ef Include some existing manual tests in the Qbs build system
Change-Id: Iceb346c42ff798430fb4ee6887b34f89768f014b
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2020-12-11 13:35:11 +00:00