diff options
author | Robert Loehning <robert.loehning@qt.io> | 2016-05-26 12:32:00 +0200 |
---|---|---|
committer | Robert Loehning <robert.loehning@qt.io> | 2016-05-26 11:48:03 +0000 |
commit | b2f869c4111087ead3caf672cd3088deefb35ff4 (patch) | |
tree | 372ce267a944011177ddfe57af3339d89015314c | |
parent | 91d7886313c8df00ae0b53acb90676aa802f768e (diff) | |
download | qt-creator-b2f869c4111087ead3caf672cd3088deefb35ff4.tar.gz |
Squish: Test code model's reaction to decimal separator in float
Must not be interpreted as member access operator.
Task-number: QTCREATORBUG-16188
Change-Id: Iec252fbc63899cef5b004a5770e3ebee5af7188e
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
-rw-r--r-- | tests/system/suite_CSUP/tst_CSUP01/test.py | 13 | ||||
-rw-r--r-- | tests/system/suite_editors/tst_memberoperator/testdata/usages.tsv | 2 |
2 files changed, 15 insertions, 0 deletions
diff --git a/tests/system/suite_CSUP/tst_CSUP01/test.py b/tests/system/suite_CSUP/tst_CSUP01/test.py index 3b3e6be220..5971d186f9 100644 --- a/tests/system/suite_CSUP/tst_CSUP01/test.py +++ b/tests/system/suite_CSUP/tst_CSUP01/test.py @@ -78,6 +78,19 @@ def main(): type(waitForObject(":popupFrame_Proposal_QListView"), "<Tab>") test.compare(str(lineUnderCursor(editorWidget)).strip(), "void", "Step 4: Verifying if: Word 'void' is completed because only one option is available.") +# Step 4.5: Insert text "2." to new line and verify that code completion is not triggered (QTCREATORBUG-16188) + resetLine(editorWidget) + lineWithFloat = "float fl = 2." + type(editorWidget, lineWithFloat) + try: + waitForObject(":popupFrame_Proposal_QListView", 5000) + if useClang and JIRA.isBugStillOpen(16188): + test.xfail("Typing a float value triggered code completion") + else: + test.fail("Typing a float value triggered code completion") + except: + test.compare(str(lineUnderCursor(editorWidget)), " " + lineWithFloat, + "Typing a float value does not trigger code completion") # Step 5: From "Tools -> Options -> Text Editor -> Completion" select Activate completion Manually, # uncheck Autocomplete common prefix and press Apply and then Ok . Return to Edit mode. test.log("Step 5: Change Code Completion settings") diff --git a/tests/system/suite_editors/tst_memberoperator/testdata/usages.tsv b/tests/system/suite_editors/tst_memberoperator/testdata/usages.tsv index 98fdd1aebb..9d44b0431f 100644 --- a/tests/system/suite_editors/tst_memberoperator/testdata/usages.tsv +++ b/tests/system/suite_editors/tst_memberoperator/testdata/usages.tsv @@ -2,6 +2,8 @@ "" "" "syntaxError" "." "syntaxError." "" "" "argc" "." "argc." "" "" "argv[0]" "." "argv[0]." +"" "" "2" "." "2." +"" "" "float fl = 2" "." "float fl = 2." "" "QCoreApplication qa;" "qa" "." "qa." "" "QCoreApplication *p;" "p" "." "p->" "" "QCoreApplication &ref = a;" "ref" "." "ref." |