aboutsummaryrefslogtreecommitdiffstats
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
* Dumpers: Quit test immediately if make failsOrgad Shaneh2017-09-271-0/+1
| | | | | | Change-Id: Idee48a997dce047e5ad90d133fce9c610f609a9a Reviewed-by: Christian Stenger <christian.stenger@qt.io> Reviewed-by: hjk <hjk@qt.io>
* Dumpers: Fix tests execution on Windows/MinGWOrgad Shaneh2017-09-271-9/+12
| | | | | Change-Id: Ie6207f5edba865e880249d6f70daf1e9c72c4163 Reviewed-by: hjk <hjk@qt.io>
* Dumpers: Modernize testsOrgad Shaneh2017-09-271-45/+38
| | | | | | | | * Remove QLatin1* * foreach -> for Change-Id: Ifac9b14b9904df8d112c71f791f1e0bd45ffc584 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* C++: Fix crash with invalid raw string literalNikolai Kosjar2017-09-202-0/+21
| | | | | | | | | | | | | | | | While parsing a document Bind::asStringLiteral() Token::spell() was called for a raw string literal token with a Token::literal nullptr. This is due scanRawStringLiteral() not properly aborting for invalid/incomplete code and that the code paths handling multi-line-raw-strings were not limited to the highlighting case. Address both cases. Task-number: QTCREATORBUG-18941 Change-Id: I489d288ccbd7b59be396dada846613ff555436cf Reviewed-by: Eike Ziller <eike.ziller@qt.io> Reviewed-by: Orgad Shaneh <orgads@gmail.com>
* Dumpers: Print readable output in testsOrgad Shaneh2017-09-191-10/+10
| | | | | Change-Id: I32864c9c1b8fe60b5b01423f68e63a3c00b936f8 Reviewed-by: hjk <hjk@qt.io>
* Squish: Enclose code model tests in sectionsRobert Loehning2017-09-1910-307/+326
| | | | | Change-Id: I4478acfc5ea7b3fa22d1cd17576e04fdda81dbb9 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* Dumper: Dump CHAR/WCHAR arrays as stringsOrgad Shaneh2017-09-181-3/+16
| | | | | Change-Id: I78bdb181e27cc858356c9026fc960135b54cdcbb Reviewed-by: hjk <hjk@qt.io>
* Squish: Update expected tree for tst_cmake_speedcrunchRobert Loehning2017-09-121-2/+0
| | | | | | | | Needed since 3bb3f4af56b538dbf70a907f2ca5d633f8379608 filters out duplicates. Change-Id: If7e56914feb9d22c1620822fbb363b55b894a41a Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* Squish: Update language testChristian Stenger2017-09-121-0/+2
| | | | | | | | Danish and Ukrainian had been added a while ago, so add them to the list of languages to check. Change-Id: I92c507e3a567efa39d7295559af0fb16bbcd1bb6 Reviewed-by: Robert Loehning <robert.loehning@qt.io>
* Clang: Avoid waiting plugin side if (re)parse failsNikolai Kosjar2017-09-121-0/+49
| | | | | | | | | | | | | | | | | | If a parse or reparse operation fails, the corresponding translation unit is "not intact" anymore and further job requests for that translation unit will be silently discarded without notifying the plugin. This is especially problematic when the plugin expects/waits (for) a certain message. A parse/reparse can fail due to e.g. an invalid commandline or an internal crash. In such a case, ensure to send some dummy results. Task-number: QTCREATORBUG-18864 Change-Id: Ida9b8066fd55e64027a9b0d8bd5cf365b16a7356 Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io> Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
* Squish: Update expected combo box in tst_WELP01Robert Loehning2017-09-081-1/+1
| | | | | Change-Id: I35f40a637a6914bea2057b951409b21b7ce90c8d Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* Squish: Workaround Squish issues when using nativeTypeChristian Stenger2017-09-072-5/+9
| | | | | | | | | | | | When using nativeType() Squish sends single key press events for any char to type. nativeType() does not wait until these events have been processed which leads to complete useless time measurings inside tst_tasks_handling as timestamps are taken too early if nativeType had to be used - which happens when a native FileDialog is used. Change-Id: I446de898fd99b2e169ca39bef1adb4306d6ee530 Reviewed-by: Robert Loehning <robert.loehning@qt.io>
* UnitTests: Disable related tests if suspend-patch is missingNikolai Kosjar2017-09-073-9/+17
| | | | | Change-Id: Ifdccf2e5842aff13528e52caa4dfd3288214d723 Reviewed-by: Marco Bubke <marco.bubke@qt.io>
* Welcome: Squish: Assign object name to fix Squish testsChristian Stenger2017-09-061-4/+2
| | | | | | | | | | Latest change of adding QScrollArea around Welcome's sidebar made the objects lookup fragile. Using the QScrollArea inside Squish tests helped for some but not all lookups. Simplify the lookup by assigning an object name. Change-Id: I5f37ee69bf20eaf02c9717cbaa5ba541d8ffbc17 Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
* Squish: Store text of item as early as possibleRobert Loehning2017-09-011-1/+1
| | | | | | | | It seems that item.text can change after (not during!) the double-click. Storing it earlier to workaround this problem. Change-Id: I5da4ae7ea8e19b945e56349c2236940a9e5731cb Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* PortGatherer: Add test for Mac's netstat output.hjk2017-08-301-0/+10
| | | | | | Change-Id: I6df357502e5621e858a848c567fe1590762d5fc1 Reviewed-by: Filipe Azevedo <filipe.azevedo@kdab.com> Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* Squish: Fix searching for filename in windowTitleRobert Loehning2017-08-305-7/+7
| | | | | | | | | Currently, only the end of a filename as actually compared since the title also contains "filename.h" when the title starts with "otherfilename.h" Change-Id: I60dd4dc1fd7c53fee2ddbc44953bcfe4d75c7530 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* Squish: Add possible error and respective handlingChristian Stenger2017-08-291-6/+20
| | | | | | | | | When using pastebin there can be various errors. Add another one and try to handle it gracefully as this is a server side error we cannot influence ourselves. Change-Id: I2bcd5b7752bfbb98e2b3fd41cc8ebb9daf0ebf32 Reviewed-by: Robert Loehning <robert.loehning@qt.io>
* Clang: Tests: Improve DocumentSuspenderResumerNikolai Kosjar2017-08-241-3/+14
| | | | | | | | * Use IsEmpty() * Set up proper error printer Change-Id: I9d4750f8e69e0660ece33015d439c796077d1727 Reviewed-by: Marco Bubke <marco.bubke@qt.io>
* ProjectExplorer: Fix parsing ports from netstat output on Windowshjk2017-08-241-0/+33
| | | | | | | Handle IPv6, and do not try to interpret the result as hex. Change-Id: I700c233d03cc706bc8712ab9fabee75d7f126df3 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* Clang: Ensure that an unparsed translation unit is not suspendedNikolai Kosjar2017-08-231-0/+27
| | | | | | | | Currently this might happen when registerTranslationUnitsForEditor is called with visible documents that are not the ones that are registered. Change-Id: I9ae5f75c8bbff6a11161a3387633726066001062 Reviewed-by: Marco Bubke <marco.bubke@qt.io>
* Squish: Update workarounds for Clang Code ModelRobert Loehning2017-08-214-8/+2
| | | | | Change-Id: Ib7f5bb5670ff393f2b3bbecb1398bf382d6cca66 Reviewed-by: Robert Loehning <robert.loehning@qt.io>
* Squish: Update expected project treesRobert Loehning2017-08-213-442/+154
| | | | | | | Generated files and empty directories are now hidden by default Change-Id: I8f3d53e9f5619b6d9aed938f90f5ec84e50b94ea Reviewed-by: Robert Loehning <robert.loehning@qt.io>
* Clang: Fix highlighting of template function in using declarationNikolai Kosjar2017-08-142-0/+10
| | | | | | | | | | | This completes commit a3a62e78f7378182138555936b45a885865c00ad Clang: Fix highlighting of function in using declaration Change-Id: I3c163096374d7a1f45a590bb8ebfe5f5a1f8d417 Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io> Reviewed-by: Marco Bubke <marco.bubke@qt.io>
* Debugger: Add some hints on how the Python manual test workshjk2017-08-103-1/+6
| | | | | Change-Id: I7a20451739c759510ea2d400493985ae543c6965 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* C++: Do not insert matching } within stringNikolai Kosjar2017-08-071-0/+7
| | | | | | | | | | | Regression from commit a6aa287720112c70c1363bcb46d55d438fe57eac C++: Fine-tune auto insertion of '}' Change-Id: I3ede8c7a1e3c73708d5d5a59c314e4b4596976b2 Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io> Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* Squish: Remove workaround for fixed issueChristian Stenger2017-08-071-5/+1
| | | | | Change-Id: I7cc40e83400bcf2614ae6eb34eecefa9bb75d172 Reviewed-by: Robert Loehning <robert.loehning@qt.io>
* Squish: Work around Squish issue on macOS if necessaryChristian Stenger2017-08-071-2/+8
| | | | | Change-Id: Ib6a6179ba51a907ee5e7aa1a6e30f345da217e52 Reviewed-by: Robert Loehning <robert.loehning@qt.io>
* Squish: Add special menu handling for macOSChristian Stenger2017-08-071-1/+4
| | | | | | | | | | | When sub menus are going to get triggered the mouse interaction done by Squish might close the sub menu with the mouse click - avoid this by explicitly setting the mouse cursor onto the item before clicking it. Change-Id: Id2afe9823304caac1bd66a423fe4a0ee12993ddd Reviewed-by: Robert Loehning <robert.loehning@qt.io>
* qbs build: Do not access the bundle module unconditionallyChristian Kandeler2017-08-031-1/+1
| | | | | | | We should not rely on its presence on non-Darwin platforms. Change-Id: I3fa722038f9c2d1139f6e1dc8c49d1c4d2fe0bee Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Clang: Suspend least recently used translation unitsNikolai Kosjar2017-08-038-0/+485
| | | | | | | | | | | | | | | | | | | | ...to free some memory. The translation units of the 7 most recently used documents ("hot documents", tracked by document visibility) are kept in memory. Translation units of other documents are suspended and will be resumed once they become visible again. The resumption of a translation unit needs the same time as reparse (since it is a reparse effectively). The number of hot documents can be modified by the run time environment variable QTC_CLANG_HOT_DOCUMENTS=N. Visible documents are always hot. Task-number: QTCREATORBUG-11640 Change-Id: I68ecd2b1373e303372300203e42d90f65a4b39b3 Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io> Reviewed-by: Marco Bubke <marco.bubke@qt.io>
* Clang: Use document visibility as jobrequest conditionsNikolai Kosjar2017-08-031-21/+2
| | | | | | | | | This is in preparation for a follow-up change that will add jobs that also operate on invisible documents. Change-Id: I2a0fc3b95cc5ab2e267429134a534df64c901376 Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io> Reviewed-by: Marco Bubke <marco.bubke@qt.io>
* Clang: Fix incomplete JobRequest in testsNikolai Kosjar2017-08-032-0/+2
| | | | | | Change-Id: Ibbe8f2722c81393d997efb33e6b29e01fde5eee7 Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io> Reviewed-by: Marco Bubke <marco.bubke@qt.io>
* Squish: Add some hints for the setup on macOSChristian Stenger2017-08-021-0/+25
| | | | | Change-Id: I7aaaee9f32b22f632bdd80c2bcfb1f0cc19f1c8d Reviewed-by: Robert Loehning <robert.loehning@qt.io>
* Squish: Update expected textsChristian Stenger2017-08-011-4/+4
| | | | | Change-Id: I0959635cdfe92335c0a5582119e145c8e7ea88b2 Reviewed-by: Robert Loehning <robert.loehning@qt.io>
* Squish: Update expected completionsRobert Loehning2017-08-011-6/+6
| | | | | Change-Id: I0df3f777cb04e0609be01f5f0acf8b909f64ebd3 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* Squish: Replace Qt4 SDK by self-built Qt 4.8.7Robert Loehning2017-07-3127-253/+574
| | | | | | Change-Id: If990367afb01aae94755930c02c81ae82b23bb8f Reviewed-by: Robert Loehning <robert.loehning@qt.io> Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* Clang: Fix highlightingmark testMarco Bubke2017-07-311-13/+10
| | | | | Change-Id: I2c25e06e29e9024e8d3c38536e0e1f93ef65b7e8 Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
* Clang: Fix tests for output argumentsMarco Bubke2017-07-271-4/+4
| | | | | Change-Id: I9aeef5758c6291f19efc3d72d5d985adad4c13ab Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
* Unit tests: Fix ProjectInfoGenerator.* testsNikolai Kosjar2017-07-271-2/+5
| | | | | | | | | | ...by adapting to recent mime type changes: commit e8e46ab553bce9aac9adcaf2ac4ee1207b69ac93 Plugins: Fix that mimetype definition was not valid JSON Change-Id: Iac416ab481814e4488fac4d818c51c647c1ec349 Reviewed-by: Eike Ziller <eike.ziller@qt.io>
* UnitTests: Fix printerMarco Bubke2017-07-261-5/+5
| | | | | | | Fix recursion for QVariant printers. Change-Id: I1473a94102d0f4446e8033f4c1828735614cdfa3 Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
* Clang: Tests: Sort files in unittest.proNikolai Kosjar2017-07-241-59/+59
| | | | | Change-Id: I5473230ba9bc1b6c1a9520971d66918d545c9e5b Reviewed-by: Marco Bubke <marco.bubke@qt.io>
* Clang: Show all tokens of a getter as output argumentMarco Bubke2017-07-242-0/+41
| | | | | | | | | f(x.get()); -> x.get() should be shown as a output argument Task-number: QTCREATORBUG-18591 Change-Id: I99f5637660bcd0a889338ebfa6737d79de226f87 Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io> Reviewed-by: Marco Bubke <marco.bubke@qt.io>
* Clang: Tool tips for clang query diagnosticsMarco Bubke2017-07-241-1/+260
| | | | | | | | If you hover a diagnostics in for a clang query you get now a simple tool tip. Change-Id: I6352dd3d4b9a33c183e69037eac903469b90eea4 Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
* Clang: Remove pointer arguments from output argumentMarco Bubke2017-07-242-5/+15
| | | | | | | | | Non constant pointers are used many times as non output arguments, so you get misleading information. Task-number: QTCREATORBUG-18591 Change-Id: Ic5f987db44ad63a0b1a38fd59cd807db5f2acc8f Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
* C++: Fine-tune auto insertion of '}'Nikolai Kosjar2017-07-211-24/+103
| | | | | | | | | | | | | | Do not insert for these cases: * <Cursor>{ * namespace X <Cursor> * if the next block is indented, like e.g.: if (e) <Cursor> g(); * on empty line if text before looks like a finished statement or scope opening/end Change-Id: Id9decc1e964a775724a929c2a3e79b5283105560 Reviewed-by: David Schulz <david.schulz@qt.io>
* C++: Add tests for MatchingText::contextAllowsAutoParenthesesNikolai Kosjar2017-07-212-1/+182
| | | | | Change-Id: I4c2bdf55112f473770db1515bd412215685bfe04 Reviewed-by: David Schulz <david.schulz@qt.io>
* Clang: Add clang query paneMarco Bubke2017-07-2018-255/+911
| | | | | | | We now support highlighting for an example text and for the query. Change-Id: I88c415ff871cf3e4c2d4fc83d60a8555bf0ce08a Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
* Squish: Use all lowercase when searching in locatorRobert Loehning2017-07-191-1/+1
| | | | | | | | As soon as an uppercase letter is being used, the locator becomes case-sensitive. Change-Id: Id392a762282f824c51a19c26721f820dc3dd3b8e Reviewed-by: Christian Stenger <christian.stenger@qt.io>
* Squish: Update configuration check in tst_cli_output_consoleRobert Loehning2017-07-191-1/+2
| | | | | Change-Id: I0890ce54b76ec8d01095e8ed0c5bbb4dc4f18390 Reviewed-by: Christian Stenger <christian.stenger@qt.io>