aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto
Commit message (Collapse)AuthorAgeFilesLines
* Utils: Fix persisting of QRectChristian Stenger2020-08-197-0/+124
| | | | | | | | | | | | And pass explicitly a QVariant to the writer to avoid unexpected behavior when trying to store the geometry of a widget. This resulted in a warning for any session where the user had used the debugger at least once. Change-Id: I5cb2352ab29ff7d2a64c84ffcdf040efe6d04b94 Reviewed-by: Eike Ziller <eike.ziller@qt.io> Reviewed-by: hjk <hjk@qt.io>
* Merge remote-tracking branch 'origin/qds-1.59' into 4.13Tim Jenssen2020-08-135-11/+148
|\ | | | | | | Change-Id: Ic720f3adab305c5ef8cd10e713ccabf510eff0c0
| * QmlDesigner: Split messaging and process for puppetsMarco Bubke2020-08-105-11/+148
| | | | | | | | | | | | | | | | | | | | This will make it easier to implement custom puppets. The new connection manager will restucture the code and it add a mechanism to capture data too. Task-number: QDS-2529 Change-Id: I5d15c3303ef1c9a3e25ba197d350e0d561ce813a Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
* | CPlusPlus: Fix expectations in preprocessor autotestChristian Kandeler2020-08-121-18/+19
| | | | | | | | | | | | | | | | ... regarding unfinished macro calls. Amends df0ffd8bb8. Change-Id: Ia7b8752860ac9207e702697cbee87f16a39dd1dd Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* | qmljs: qtdeclarative change 9ab1a6759018b78b0f160c5286f8b0235a34ec50Fawzi Mohamed2020-08-032-0/+13
| | | | | | | | | | | | | | | | | | | | Support required list properties The corresponding rules were missing so far. Fixes: QTBUG-85716 Change-Id: Iaf0cbfbb8736929a213bd6bf329bb2ebdde652c4 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* | Tests: Fix codemodel check testChristian Stenger2020-07-303-31/+41
| | | | | | | | | | Change-Id: I9ca0fec928ac90fd5951fc54963ba5e96d5a53a6 Reviewed-by: Fawzi Mohamed <fawzi.mohamed@qt.io>
* | Tests: Fix nullptr accessChristian Stenger2020-07-301-0/+1
| | | | | | | | | | Change-Id: I4e2bf36dfa6e16dfd9924c865bd9a997750243a2 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Debugger: Remove name demanglerChristian Kandeler2020-07-206-656/+0
| | | | | | | | | | | | | | Never been used, completely outdated, fails autotest. Change-Id: I2c1808b4a66e9abdb839670eeae3e5226c7246ba Reviewed-by: hjk <hjk@qt.io>
* | qbs build: Fix sdktool autotestChristian Kandeler2020-07-061-1/+1
| | | | | | | | | | Change-Id: I069d9b3eaea295efa8d78d4d96b52b61cecbb783 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* | Debugger: Set WITH_DEBUGGER_DUMPERS to ON by defaulthjk2020-07-061-1/+1
| | | | | | | | | | | | | | | | | | | | | | The option went in with the initial CMale port, presumably because the test itself created and compile qmake projects at the time. I do not think it makes sense to leave out existing tests by default, even if they run for some time. Change-Id: I7ff055a2a432b9d8f6af16f7da63ebc56995c31e Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* | QmlDesigner: Fix test buildThomas Hartmann2020-07-011-1/+2
| | | | | | | | | | Change-Id: Ib24054b9caa1a2b1404c8af7af7f85bc3de1e6b2 Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
* | QmlDesigner: Fix testsThomas Hartmann2020-06-301-1/+1
| | | | | | | | | | Change-Id: I74442bf004a462d5d310f128b64f8bc82073d822 Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
* | CMake build: Make option to include dumper tests discoverableEike Ziller2020-06-301-0/+1
| | | | | | | | | | Change-Id: I9828f362561b8392d31a56f8a60fe9531accf4ce Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* | CMake build: Remove timeout for dumper testsEike Ziller2020-06-301-0/+1
| | | | | | | | | | | | | | | | | | They take much longer, but are also optional. Makes it possible to run via e.g. "ctest -V -R tst_debugger_dumpers" Change-Id: I8bbda6ca36e25cd896b1f3be5d1696a27b8acc53 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io> Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
* | Tests: Fix deprecation warningChristian Kandeler2020-06-261-1/+1
| | | | | | | | | | | | Task-number: QTCREATORBUG-24098 Change-Id: Icea21e446173537d8fdb8113f1eff7d7176c34b3 Reviewed-by: hjk <hjk@qt.io>
* | C++: Fix auto variable resolving for template class constructor callVolodymyr Zibarov2020-06-221-0/+108
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Code snippet: template<class T> struct MyStruct { int value; }; int main() { auto s = MyStruct<int>(); s.value; // "value" is not found } This fixes find usages for unique_ptr declared as auto like this: auto ptr = std::unique_ptr<MyStruct>(new MyStruct()); ptr->value; Also fixes in-place constructors: std::unique_ptr<MyStruct>(new MyStruct())->value; Fixes: QTCREATORBUG-15364 Change-Id: I8d452a77fe85e63665ec8d4c4afbcf8aad063121 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Debugger: Remove QLinkedList occurrences from manual testshjk2020-06-181-0/+1
| | | | | | | | | | | | | | | | And restrict the auto test to Qt<6. Task-number: QTCREATORBUG-24098 Change-Id: Idfbe94bc1a4b2d5a8c23a07a031520775bb17cd3 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* | CPlusPlus: Fix lexer crashChristian Kandeler2020-06-181-0/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | At some point in the preprocessing stage, some tokens get "squeezed", so their associated string no longer refers to the document content, but only to their own symbol. However, there is at least one context that operated under the assumption that the token's offset still pointed into the "global" string. As the token's offset is zero after parsing, this lead to the same piece of code being preprocessed in an infinite loop. Fixes: QTCREATORBUG-19525 Change-Id: I231ba51811cfa0b5c6dfe7f75fe0384472252c6f Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* | Debugger: Start making auto tests work using cmakehjk2020-06-172-54/+192
| | | | | | | | | | | | Change-Id: Ibe6c9bdfb52a16171e6f6acb841f185d936878f3 Reviewed-by: hjk <hjk@qt.io> Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* | Tests: Fix Qt 5.15 deprecation warningsChristian Kandeler2020-06-172-10/+10
| | | | | | | | | | Change-Id: I458cced795f29479557853919bd6d317e5870f07 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* | C++: Fix Find Usages false positive results for function argumentsVolodymyr Zibarov2020-06-151-0/+113
| | | | | | | | | | | | | | | | | | | | | | | | | | Code snippet: void bar(); // call find usages for bar from here void foo(int bar); // bar from here should not be in results Add test for member function false positives, that is part of QTCREATORBUG-2176. That was already fixed before. Fixes: QTCREATORBUG-2176 Change-Id: I9a079caa83bbaea1edb7ba6aeb151d4d4c77952f Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | C++: Fix find usage to see Catch test functions bodiesVolodymyr Zibarov2020-06-151-0/+40
| | | | | | | | | | | | | | | | | | | | | | | | Catch test functions defined with function-like macros. To speed-up semantic analysis, find usages does not expand function-like macros. Semantic fails with "expected a function declarator" on such functions and skips function body. To avoid that, we create dummy function type specifically for this case Change-Id: Ie2f2464ee57aa4dc86eed07b8b699458f95c0266 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Merge remote-tracking branch 'origin/4.12'Eike Ziller2020-06-151-26/+170
|\ \ | | | | | | | | | | | | | | | | | | Conflicts: src/plugins/cmakeprojectmanager/fileapiparser.cpp Change-Id: I39f8c2be859be043f506bef77de9bb5b42d38165
| * | Debugger: Fix QJson dumper for Qt >= 5.15hjk2020-06-081-26/+170
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Storage is internally based on QCbor now. Since this works better when having dumpers for QCbor values, add those, too, for Numbers, Strings, Arrays, Maps for now. None of the custom types. Fixes: QTCREATORBUG-23827 Change-Id: Idf281d859aaf8556d9895646bbc091af85b34157 Reviewed-by: David Schulz <david.schulz@qt.io>
* | | Merge remote-tracking branch 'origin/qds-1.59'Eike Ziller2020-06-0837-15/+2948
|\ \ \ | | |/ | |/| | | | | | | | | | | | | | | | Conflicts: src/plugins/qmldesigner/components/formeditor/formeditoritem.cpp src/plugins/qmlpreview/qmlpreviewconnectionmanager.cpp Change-Id: Ifa7c66330c1995378280cdb4c57c30015dc11b68
| * | Add option to apply style sheet coordinatesMichael Brüning2020-06-044-0/+639
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Enables the user to have pixel positions in the style sheet even if the template does not use pixel positioning. Also adds some more ordered properties to make the test case deterministic. Task-number: QDS-2208 Change-Id: I79b6af0c24539d1b9eb03dcf0fb52bb078d74afe Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
| * | Correct text alignment preservation and add basic options parsingMichael Brüning2020-06-024-25/+211
| | | | | | | | | | | | | | | | | | | | | | | | Also add a test case and Remove some dead code along the way. Task-number: QDS-2071 Change-Id: If34d4e152860ec9ab098f07e36e3a5dc4368c67f Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
| * | QmlDesigner: Fix test data for StyleMergerThomas Hartmann2020-06-024-44/+21
| | | | | | | | | | | | | | | | | | | | | | | | * This seems be the correct expected outcome. * Minor fix in SwitchTemplate Change-Id: I5de04d943d3522a37ac1664157f384594ddddcde Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
| * | Add some more tests for automatic stylesheet preprocessingMichael Brüning2020-06-024-5/+186
| | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, the tests fail, but the output is by and large correct. There are some issues that still need to be analyzed. Task-number: QDS-2071 Change-Id: Idb4618171a7256ec527368d6079c756eb734db82 Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
| * | Adjust test case data for complex test and reactivate itMichael Brüning2020-06-023-13/+18
| | | | | | | | | | | | | | | Change-Id: I5e61971ff420f3193bca1f63040044833e26cca8 Reviewed-by: Michael Brüning <michael.bruning@qt.io>
| * | Add stylesheet mergerMichael Brüning2020-05-2730-15/+1960
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Adds classes to merge a template qml file and a qml stylesheet that have been exported from other design tools into a resulting qml file that can be used for further processing in Qt Design Studio. Current issues: * Sometimes it makes sense to define width and height if an anchor is present, but most of the time not. * Actually if the hierachy was defined (e.g. Text item not child of background) most likely the anchors should be ignored. But this would be just a "dirty" heuristic. I suggest to let the template decide. If the template has anchors those have "precedence". It is always possible to define templates without anchors. Task-number: QDS-2071 Change-Id: I9159514a8e884b7ffc31897aef4551b5efbbcb87 Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
* | | Merge remote-tracking branch 'origin/4.12'Eike Ziller2020-06-081-1/+6
|\ \ \ | | |/ | |/| | | | | | | | | | | | | | | | | | | Conflicts: cmake/QtCreatorIDEBranding.cmake qbs/modules/qtc/qtc.qbs qtcreator_ide_branding.pri Change-Id: I19a7406f7e387b53f1e7b3f08a0b4c89a377ab82
| * | Debugger: Adapt offset tests to changed QDateTime structure layouthjk2020-06-041-1/+6
| |/ | | | | | | | | | | | | Chandge with 5f1f0fe0b71c in qtbase. Change-Id: Ifceac5125f974a1ebd2ab2e358ba906188d451a2 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | C++: Fix variable template parsing in expressionVolodymyr Zibarov2020-06-042-0/+58
| | | | | | | | | | | | | | | | | | | | | | Fix parser to not fail on TemplateId without parentheses, for example: int i = foo<int> + foo<char>; This fixes std::pair structure parsing in MSVC headers and find Usages to work with pair->first and pair->second. Change-Id: Ic300ea99d44a749705430d5eb47b2744715af995 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | CppTools: Fix formatting for new-style function declarationChristian Kandeler2020-06-041-0/+1
| | | | | | | | | | | | Fixes: QTCREATORBUG-23502 Change-Id: Ie80fe9aa77ffbf0b9ecc531841e78f2bd80de37e Reviewed-by: Cristian Adam <cristian.adam@qt.io>
* | Debugger: Fix misleading indentationChristian Kandeler2020-06-041-4/+4
| | | | | | | | | | Change-Id: I20188acb2d00c255984a05f522bfca7938639a6b Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* | ProWriter: Do not insert a backslash when adding new filesChristian Kandeler2020-06-021-19/+19
| | | | | | | | | | | | | | | | ... if the previous line already has a trailing backslash. Fixes: QTCREATORBUG-24083 Change-Id: Ieabce541da2ef55bcbf3bd14d139b14f3a7575c7 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* | C++: fix built-in code model to work with shared_ptr on MSVC 2017Volodymyr Zibarov2020-05-293-1/+554
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These changes target Find Usages feature to work with shared_ptr. Improve libs/3rdparty/cplusplus and plugins/cplusplus: parse __declspec() attribute, call to variadic function template without specified template arguments, if constexpr, c++11 attributes [[value]], function templates with default parameters, resolve order for function vs template with default parameter, template operator->() with default arguments, template specialization with numeric values, find best partial specialization, fix partial specialization for non-first specialized argument Fixes: QTCREATORBUG-7866 Fixes: QTCREATORBUG-20781 Fixes: QTCREATORBUG-22857 Fixes: QTCREATORBUG-17825 Change-Id: I31a080f7729edfb2ee9650f1aff48daeba5a673b Reviewed-by: Christian Kandeler <christian.kandeler@qt.io> Reviewed-by: Nikolai Kosjar <pinaceae.pinus@gmail.com>
* | Built-in lexer: Recognize also reserved user-defined literalsChristian Kandeler2020-05-282-1/+3
| | | | | | | | | | | | | | | | | | | | | | Otherwise, we trip over uses of operators from the standard library such as std::chrono's operator"" ms(), potentially breaking basic code navigation. Amends 425811291d. Fixes: QTCREATORBUG-24067 Change-Id: I3b2863ce88ee3787414e7a1acdf25f368041cdb4 Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
* | C++: Add tests for recent indentation fixesChristian Kandeler2020-05-271-0/+25
| | | | | | | | | | Change-Id: I90ae2da3a82bff2e966c4327cf8e42f7ebbddd27 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | Debugger: Drop 'set print object on' for GDBhjk2020-05-251-1/+0
| | | | | | | | | | | | | | | | | | This does not seem to affect the code paths we are using through Python. Task-number: QTCREATORBUG-23965 Change-Id: I2e20d6d3c1937d56293e81b74c453e83a92ddc4c Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* | QmlJS: Add workaround for missing imports in Qt >=5.15.0Christian Kamm2020-05-211-4/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The QtQuick module plugins.qmltypes in Qt 5.15.0 do not contain QML types like QtObject. Instead, they are found in the QtQml module. Something similar applies to QtQml and QtQml.Models and QtQml.WorkerScript. As Qt 5.15 can't use the "import" command in the qmldir file, this code instead detects the 5.15 QtQuick and QtQml modules and adds the dependent imports manually, as a workaround. Change-Id: I982e349298eb7200372390dfc384fb43a762b253 Task-number: QTCREATORBUG-23986 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | QmlJS: Use "import" commands from qmldir filesChristian Kamm2020-05-2112-3/+693
| | | | | | | | | | | | | | | | | | | | | | | | | | | | qmldir files can have lines like "import QtQml". These were already parsed, but not stored in LibraryInfo. Store them. When imports are resolved in Link and a library has such an import, also load the module it refers to, with the same version and "as" scope. Add a test to verify the behavior works. Change-Id: I80b260bfaa36a9e5de0849fa5632b3361077ef01 Task-number: QTCREATORBUG-23986 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | Merge remote-tracking branch 'origin/4.12'Eike Ziller2020-05-151-0/+1
|\| | | | | | | | | | | | | Conflicts: src/plugins/mcusupport/mcusupportsdk.cpp Change-Id: I1583fa81adc0218ad4657baa347c08e9e29f88e6
| * qbs build: Take differences between clang and "apple clang" into accountChristian Kandeler2020-05-121-0/+1
| | | | | | | | | | | | | | | | In particular, clang with version number 10 is not really clang 10 on macOS. Change-Id: I8be489fa9cffd63c1ea8f13d181686ab1a575ec6 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* | Fix clang 10 warnings about unnecessary copies in range loopsChristian Kandeler2020-05-121-1/+1
| | | | | | | | | | Change-Id: I3b57869b5a04528518bc432b76768b01e3f53e81 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* | Merge remote-tracking branch 'origin/4.12'Eike Ziller2020-05-111-1/+10
|\| | | | | | | Change-Id: Ibbf9f16677a58bdcdd3ce63701ffa34db6f44916
| * qbs build: Suppress more warningsChristian Kandeler2020-05-071-1/+10
| | | | | | | | | | | | | | Amends d08e5c33ff. Change-Id: Ic842dda51b21427e1989190b44508d54aa1e7120 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* | Merge remote-tracking branch 'origin/4.12'Eike Ziller2020-05-041-2/+5
|\| | | | | | | Change-Id: Ib95ec2c50c4bbaefd4ed0ec5af191ccc846c824f
| * qbs build: Fix sdktool autotest on WindowsChristian Kandeler2020-05-041-2/+5
| | | | | | | | | | | | | | | | Make sure to fix the path separators for the macro that gets passed on the command line. Change-Id: I444883e6fc5a2b49d73a1fa52aa1ea26b207185c Reviewed-by: Christian Stenger <christian.stenger@qt.io>