Commit Graph

178 Commits

Author SHA1 Message Date
Robert Löhning
945f0462f8 SquishTests: Wait until exactly one proposal is being shown
...so we don't accidentally use a wrong one.

Change-Id: I4c08e11aab34b8649f40ba14385492b17e656385
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2024-07-19 15:23:58 +00:00
Christian Stenger
410b275eca SquishTests: Attempt to stabilize designer test
The switch to cmake broke this test completely as qmake handles
changes to ui files differently.
Changing a ui file needs re-execution of moc which is not done
automatically for cmake except when building.
Beside this the cmake project manager seems to inform the code
model about respective changes significantly later, if at all.
So, we explicitly trigger a build now after changing the ui file
and explicitly ensure the code model treats the file correctly
by closing and re-opening it.

Change-Id: Icb9cfb572c1442eff1bebc9c29fdee55155ca287
Reviewed-by: Robert Löhning <robert.loehning@qt.io>
2024-07-19 11:10:08 +00:00
Robert Löhning
2970b6c85e SquishTests: Use newest Kit in tst_designer_edit
The old MinGW can't compile the used project anymore.
Even configuring already fails. Testing compatibility
with old Qt versions and compilers isn't the purpose
of this test, so it can simply move to newer ones.

Change-Id: Ie21a5a726c33b4073f2aa4d955e2e5ea943bf9bc
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2024-07-19 08:59:22 +00:00
Robert Löhning
394e9a9fb3 SquishTests: Don't proceed in hopeless situation
When the GenericProposalWidget is not being shown,
there's no point in trying to use it.

Change-Id: Ibe6f3ed9230fdc41271f5ff8538bd863da3d0ab3
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-05-16 07:05:07 +00:00
Robert Löhning
987cd409f3 SquishTests: Make sure that button in Designer is renamed properly
This misused typeLines() to close the dialog by pressing "Return".
Although the entire name of the button should be selected at first,
I witnessed the new name being appended to the old one.

The new code uses replaceEditorContent() to explicit select the old
name and replace it with the new name. After that, it explicitly
presses "Return" to close the dialog.

Change-Id: I5ec946f57000396b70428e08ab795a1ee3eba91a
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2024-04-23 12:03:13 +00:00
Robert Löhning
ec33fc0476 SquishTests: Avoid using occurrence value for SideDiffEditorWidgets
Change-Id: I7c519347a25b0c541b019dd1cae65df4a74c8826
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-04-23 09:35:37 +00:00
Robert Löhning
6838be76aa SquishTests: Fix wait condition in tst_git_local
Change-Id: I401e3c8f8f2743ff9b108d3e25693f834d61e8ac
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2024-04-17 09:10:47 +00:00
Robert Löhning
95df308bc3 SquishTests: Remove compatibility code for Python 2
Change-Id: Ibcf9a76fb163aa7167ad0ef0616c39b33c30d7c5
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2024-04-10 07:30:00 +00:00
Robert Löhning
b163044648 SquishTests: Update expected output in tst_git_clone
Change-Id: Ia0a559ee8fb24d639b913dabc1b77dd4c2286fbb
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2024-02-08 12:31:51 +00:00
Eike Ziller
10e5a27c27 Merge remote-tracking branch 'origin/12.0'
Conflicts:
	src/plugins/cmakeprojectmanager/cmakeprojectmanager.cpp

Change-Id: If96d0f0a3d48c2581e765e4afb8b23924c48bdd6
2023-12-12 10:17:39 +01:00
Christian Stenger
1633d76b76 SquishTests: Allow designer test to progress further
Explicitly chose a newer kit as the kit we would use by default
lacks some compiler features on Windows.
This patch here only fixes the test crash when trying to access
a disabled menu item due to cmake dropping out with error when
parsing the project with the active kit.
Drive by change: removed workaround for fixed bug.

Change-Id: I783626f30d27ab1852536ae0d1f936ec8323feb8
Reviewed-by: Robert Löhning <robert.loehning@qt.io>
2023-12-11 14:03:13 +00:00
David Schulz
2e93051aaf TextEditor: improve sort selected lines
Try to get a sensible scope when there is no selection when sorting
lines.

Use the indent level of the current block and select all blocks that are
not empty with the same indent level around that block before sorting
the lines.

Change-Id: I68cbd95f95a0cc4425a0339b992225c3946a6858
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-10-24 07:38:38 +00:00
Robert Löhning
b95aba56b5 SquishTests: Don't use lists of dicts
...when that doesn't have any advantages.

Change-Id: I0c58e30ae0b9e278e3336646332279f6243719d0
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-07-27 11:52:25 +00:00
Robert Löhning
a521114519 SquishTests: Don't initialize an entire list for reading one item
The point of Python3 returning objects instead of lists is that
it will iterate just as far as items are actually being used.

Change-Id: If4d9742bb47aa9cac1166a0ff6f10d211829fd85
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-07-27 11:41:40 +00:00
Robert Löhning
1487f1a0c0 SquishTests: Make sure tst_git_local cleans up properly
Creator still writes gitProject.pro.user after cleanup() ran.

Change-Id: I78c8247090a7032b21ee3a763fd390bb16f3d24b
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-07-04 12:27:45 +00:00
Christian Stenger
38cc6e533d SquishTests: Fix expected clone output
The working directory is quoted nowadays.

Change-Id: I8b4abc5d21a3adb4b07b7582c2e5f74f11da51d0
Reviewed-by: Robert Löhning <robert.loehning@qt.io>
2023-06-08 05:06:45 +00:00
Robert Löhning
0b241f42f1 SquishTests: Make suite_tools Python3 compatible
Except for tst_designer_edit which needs a bigger update.

Change-Id: I8300a9491ec34b4d8deeed39f02fc59281cc20c9
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-05-15 14:12:17 +00:00
Robert Löhning
a820b5490c SquishTests: Fix using invalid paste IDs
Change-Id: Ibc48506ff1632cbfe8d662cd00ed057af7d16a6a
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-05-15 14:12:01 +00:00
Robert Löhning
8d03220017 SquishTests: Improve log messages of exceptions
...and make them more similar to Squish's own "Error" messages.

Change-Id: If5df701d4fa01fc1c1aea94cc9778a6a5dccc44e
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-05-05 09:33:01 +00:00
Christian Stenger
ac4aaf5e23 SquishTests: Some Python3 adaption
Makes some tests succeed and lets a couple of tests get further
on macOS.

Change-Id: I9a3f124c094e67f51748ddae47d00897fe5259d5
Reviewed-by: Robert Löhning <robert.loehning@qt.io>
2023-03-27 04:36:30 +00:00
Eike Ziller
364013b9ac Merge remote-tracking branch 'origin/9.0' into 10.0
Change-Id: Ib01e191652168b2c38e80678f2f804bb95143cc5
2023-02-14 16:05:31 +01:00
Robert Löhning
b7f235edb6 SquishTests: Avoid known bug with CMake-based Widgets projects
...and start testing it again as soon as the report is closed.

Task-number: QTCREATORBUG-28787
Change-Id: Ib33efb6ef2851726a183576bfde5db0a1a5d8c38
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-02-13 21:34:56 +00:00
Eike Ziller
d278135497 Merge remote-tracking branch 'origin/9.0' into 10.0
Change-Id: I8d73198561f6ff7877d580681ca2a0018b7dc3b1
2023-02-06 10:14:18 +01:00
Christian Stenger
dd3f5d3a6a SquishTests: Fix designer test
Children inside the object inspector are sorted
lexicographically nowadays.

Change-Id: I2f704e3a3cca526246babb2b12d48fe359eb6e6b
Reviewed-by: Robert Löhning <robert.loehning@qt.io>
2023-02-03 14:26:25 +00:00
Kai Köhne
56baf8c058 Remove GPL-3.0+ from license identifiers
Since we also license under GPL-3.0 WITH Qt-GPL-exception-1.0,
this applies only to a hypothetical newer version of GPL, that doesn't
exist yet. If such a version emerges, we can still decide to relicense...

While at it, replace (deprecated) GPL-3.0 with more explicit GPL-3.0-only

Change was done by running

  find . -type f -exec perl -pi -e "s/LicenseRef-Qt-Commercial OR GPL-3.0\+ OR GPL-3.0 WITH Qt-GPL-exception-1.0/LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0/g" {} \;

Change-Id: I5097e6ce8d10233993ee30d7e25120e2659eb10b
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-01-06 11:15:13 +00:00
Robert Löhning
a3c1b35475 SquishTests: Update tst_designer_autocomplete
ui_mainwindow.h is being created on first build. While there
seems to be some workaround for qmake-based projects, cmake-based
projects can't be parsed properly before the file was written.

Change-Id: I0e9802f79b60d7d07ed92ca0ae9b93e53249b61f
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-01-02 14:19:41 +00:00
Robert Löhning
698a495972 SquishTests: Use existing function saveAndExit()
Change-Id: I2e10de8b454a69b3e4ade7520b4fa00415bcde42
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-12-15 14:45:42 +00:00
Robert Löhning
3874ac236d SquishTests: Stabilize tst_codepasting
Avoid
"Error in type() invocation: Could not
activate toplevel-window for widget"

Change-Id: Ib68a975724ad3824800bdcb542916b6644f1dc7f
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-12-15 08:33:25 +00:00
Robert Löhning
c72a93599d Squish-Tests: Use QTC_DO_NOT_PROPAGATE_LD_PRELOAD
This is a reaction to an change in Creator's handling
of environment variables. Creator now passes on
LD_PRELOAD set by Squish. This results in build errors
and crashes of started applications.

Change-Id: I39cf21c60a474d7453e9c29fd3eaf32d3f0d6806
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-10-24 19:20:07 +00:00
Eike Ziller
ea5a050c5c Merge remote-tracking branch 'origin/8.0' into 9.0
Conflicts:
	src/plugins/mcusupport/mcusupportsdk.cpp
	src/plugins/qmldesigner/components/edit3d/edit3dwidget.cpp
	src/plugins/qmldesigner/components/materialbrowser/bundleimporter.cpp
	src/plugins/qmldesigner/components/materialbrowser/materialbrowserview.cpp

Change-Id: I9317da0fc1243b9ce6d87f577aa843c51f132ad7
2022-10-18 10:48:46 +02:00
Robert Löhning
bf45aa4d24 SquishTests: Update tst_git_clone
Reverts f5f684a609

Change-Id: Iad797f87333e8d793e34c4e7df1f68c5f6508f82
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-10-17 09:35:39 +00:00
Lucie Gérard
a7956df3ca Use SPDX license identifiers
Replace the current license disclaimer in files by
a SPDX-License-Identifier.

Task-number: QTBUG-67283
Change-Id: I708fd1f9f2b73d60f57cc3568646929117825813
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2022-08-26 12:27:18 +00:00
Christian Stenger
e7f314e02a Squish: Fix local git test
The test was written for a qmake based project. Explicitly use
one as default build system has changed.

Change-Id: Iccf5761915708dd66ba73aeda25ca6b61a8c0b99
Reviewed-by: Robert Löhning <robert.loehning@qt.io>
2022-03-23 13:44:28 +00:00
Robert Löhning
f529051b58 Squish: Be fuzzy when comparing snippet fetched from Pastebin.Com
Change-Id: If08b2b9136d55e2dddca6181c1075d845422a30b
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-09-16 07:17:55 +00:00
Robert Löhning
e9f53752ee Squish: Update tst_codepasting
Change-Id: I7929a97dea0a362f07eff46a37d84b65fa546bbc
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-08-12 10:19:27 +00:00
Robert Loehning
15c9de9251 Squish: Update tst_codepasting
Change-Id: Ie908f0af267f420e107c06ae039bb085462f945d
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2020-10-20 09:26:28 +00:00
Robert Loehning
f29d73115d Squish: Avoid focus problems after cloning
The dialog shows a kind of completion popup. After that, the Locator
does not get proper focus anymore. Clicking into the dialog closes
the completion popup and seems to fix the focus problem.

Change-Id: I0ae901cc4f23b66d2c3db2c96109be79a0ded52c
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2020-08-20 10:44:12 +00:00
Christian Stenger
abffbe3806 Squish: Fix expectations
Added observation functionality for a temporary move
of the URL.
Let the test fail if the move becomes permanent.

Change-Id: I7989d654ea6e89ccba112b5cb640144afba40339
Reviewed-by: Robert Loehning <robert.loehning@qt.io>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2020-08-19 13:55:09 +00:00
Robert Loehning
f830a21bf8 Squish: Update tst_git_local
This doesn't run into QTCREATORBUG-11074 anymore, because
Creator now uses "git add --intent-to-add" when adding files.

Change-Id: I125ff29f9974efad5d22fed220f6155cc5c6804b
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2020-08-18 13:09:08 +00:00
Eike Ziller
b18711da91 Merge remote-tracking branch 'origin/4.12' into 4.13
Conflicts:
	share/qtcreator/debugger/lldbbridge.py

Change-Id: Ia444f6424fb35b9a539e157afcee868161535272
2020-07-06 16:23:13 +02:00
Christian Stenger
f5f684a609 Squish: Fix expectation when canceling a clone
Change-Id: I674324a4a98e4329c4445de69ceddeffba607ff3
Reviewed-by: Robert Loehning <robert.loehning@qt.io>
2020-07-01 09:59:40 +00:00
Robert Loehning
0575e1bbc2 Squish: Fix finding commit
Change-Id: I87d2345babe91c449c20aec8c93dbafee5773d4f
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2020-06-11 16:22:43 +00:00
Christian Stenger
7c669a06be Squish: Adapt to changed ui
Change-Id: Ibad3b2080040f7345125c549527f22f2c246fbef
Reviewed-by: Robert Loehning <robert.loehning@qt.io>
2020-06-11 13:44:24 +00:00
Christian Stenger
7778ef9597 Squish: Test newly added code paster
Change-Id: Ied5d08393185cc117a5f3986f05c3d6fbbb45718
Reviewed-by: Robert Loehning <robert.loehning@qt.io>
2020-06-08 11:28:11 +00:00
Christian Stenger
cad625c739 Squish: Remove pastecode.xyz from tests
Service is unavailable.

Task-number: QTCREATORBUG-24002
Change-Id: I012681ec1ec1deb30387e1762fe72a877e56fa10
Reviewed-by: Robert Loehning <robert.loehning@qt.io>
2020-05-19 09:53:27 +00:00
Robert Loehning
a90ec2809c Squish: Don't expect pastes to pastebin.com to appear in list
Change-Id: I02a73244e3aecad906f2c08b37d60ebe1880f534
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2020-05-12 20:29:02 +00:00
Robert Loehning
da558f3376 Squish: Don't close files before exiting Creator
It's not needed and it's fragile since
the menu item is disabled at times.

Change-Id: I0c72c5072374462d99740e7eaa752f91e019c6ee
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2020-04-02 09:46:19 +00:00
Eike Ziller
5c121d5791 Merge remote-tracking branch 'origin/4.11'
Conflicts:
	src/plugins/genericprojectmanager/genericproject.cpp

Change-Id: Ib54f1645ec70a9e6460a888a13190ede130bccca
2020-02-05 11:59:35 +01:00
Christian Stenger
9a1135776d Squish: Adapt to changed build menu entries
Change-Id: I0b9ceb8024e42960a2b915ed5e59ae5d33fa4207
Reviewed-by: Robert Loehning <robert.loehning@qt.io>
2020-01-29 06:12:29 +00:00
Robert Loehning
68fbd15299 Squish: Remove old hack for the Mac
Change-Id: I8655b8fe5a1a448995a3798fd587a01919129434
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2020-01-21 10:20:07 +00:00