blob: c23ba63fc0b0ad1469e93a962294fc20426f3d15 [file] [log] [blame]
--- RCPTT testcase ---
Format-Version: 1.0
Contexts: _ymiyse5IEeCU6db9MgIBkA,__2fEACC3EeGpvKMy1SUvBw
Element-Name: CommentsSeveralLinesInScriptView
Element-Type: testcase
Element-Version: 3.0
External-Reference: http://jira4.xored.com/browse/QS-1383
Id: _Dmr1gUu1EeG_ScHaVV2s7w
Runtime-Version: 1.5.2.201408180747
Save-Time: 9/10/14 1:41 PM
Tags: ECL_IDE_module, TestCase
Testcase-Type: ecl
------=_.description-216f885c-d591-38ce-8ea2-e4f8cb4d6ffa
Content-Type: text/plain
Entry-Name: .description
Copyright (c) 2009, 2014 Xored Software Inc and others.
All rights reserved. This program and the accompanying materials
are made available under the terms of the Eclipse Public License v1.0
which accompanies this distribution, and is available at
http://www.eclipse.org/legal/epl-v10.html
Contributors:
Xored Software Inc - initial creation and/or initial documentation
--------------------------------------------------------------------------------
Test Steps:
1. Open test case
2. Set cursor on the line and press "Ctrl+/" (for windows)
3. Make sure that this line is commented
4. Select several lines and press "Ctrl+/" (for windows)
5. Make sure that these lines are commented
------=_.description-216f885c-d591-38ce-8ea2-e4f8cb4d6ffa--
------=_.content-0a7243a0-75d3-3d5f-9791-539de0e5b7ac
Content-Type: text/ecl
Entry-Name: .content
get-view "Test Explorer" | get-tree | select "MyProject/CreateQ7Project" | double-click
with [get-editor CreateQ7Project | get-section Script | get-text-viewer] {
set-caret-pos 6 1
key-type "M1+/"
key-type "M1+s"
}
get-control Any -index 34 | key-type "M1+s"
with [get-editor CreateQ7Project | get-section Script | get-editbox] {
get-property text | equals "get-view \"Q7 Explorer\" | get-tree | get-menu \"New/Q7 Project\" | click\n"
+ "with [get-window \"New Project\"] {\n"
+ " get-editbox -after [get-label \"Project name:\"] | set-text Project\n"
+ " get-button Finish | click\n}\n"
+ "//get-view \"Q7 Explorer\" | get-tree | get-property itemCount | equals 1 | verify-true" | verify-true
get-property "styles.text" -index 32
| equals "//get-view \"Q7 Explorer\" | get-tree | get-property itemCount | equals 1 | verify-true" | verify-true
get-property "styles.fontStyle" -index 32 | equals normal | verify-true
get-property "styles.foregroundColor" -index 32 | equals "#3F7F5F" | verify-true
}
with [get-view "Test Explorer" | get-tree] {
select "MyProject/WorkspaceIsEmpty" | double-click
select "MyProject/P1 is left" | double-click
}
with [get-editor "P1 is left" | get-section Script | get-text-viewer] {
set-caret-pos 2 1
select-range 1 1 5 1
key-type "M1+/"
key-type "M1+s"
}
with [get-editor "P1 is left" | get-section Script | get-editbox] {
get-property text | equals "//with [get-view \"Q7 Explorer\" | get-tree] {\n"
+ "// get-item \"P1\"\n"
+ "// \n"
+ "//}\n"
+ "get-view \"Q7 Explorer\" | get-tree | get-property itemCount | equals 1 | verify-true" | verify-true
/*get-property "styles.text" -index 0 | equals "//with [get-view \"Q7 Explorer\" | get-tree] {" | verify-true
get-property "styles.fontStyle" -index 0 | equals normal | verify-true
get-property "styles.foregroundColor" -index 0 | equals "#3F7F5F" | verify-true
get-property "styles.text" -index 1 | equals "// get-item \"P1\"\n" | verify-true
get-property "styles.fontStyle" -index 1 | equals normal | verify-true
get-property "styles.foregroundColor" -index 1 | equals "#3F7F5F" | verify-true
get-property "styles.text" -index 2 | equals "// \n" | verify-true
get-property "styles.fontStyle" -index 2 | equals normal | verify-true
get-property "styles.foregroundColor" -index 2 | equals "#3F7F5F" | verify-true
get-property "styles.text" -index 3 | equals "//}\n" | verify-true
get-property "styles.fontStyle" -index 3 | equals normal | verify-true
get-property "styles.foregroundColor" -index 3 | equals "#3F7F5F" | verify-true*/
}
get-editor "P1 is left" | get-section Script | get-text-viewer | set-caret-pos 1 21
with [get-editor "P1 is left" | get-section Script | get-text-viewer] {
get-property "styleAtCaret.text" | equals "//with [get-view \"Q7 Explorer\" | get-tree] {\n" | verify-true
get-property "styleAtCaret.fontStyle" | equals normal | verify-true
get-property "styleAtCaret.foregroundColor" | equals "#3F7F5F" | verify-true
}
get-editor "P1 is left" | get-section Script | get-text-viewer | set-caret-pos 2 14
with [get-editor "P1 is left" | get-section Script | get-text-viewer] {
get-property "styleAtCaret.text" | equals "// get-item \"P1\"\n" | verify-true
get-property "styleAtCaret.fontStyle" | equals normal | verify-true
get-property "styleAtCaret.foregroundColor" | equals "#3F7F5F" | verify-true
}
get-editor "P1 is left" | get-section Script | get-text-viewer | set-caret-pos 3 5
with [get-editor "P1 is left" | get-section Script | get-text-viewer] {
get-property "styleAtCaret.text" | equals "// \n" | verify-true
get-property "styleAtCaret.fontStyle" | equals normal | verify-true
get-property "styleAtCaret.foregroundColor" | equals "#3F7F5F" | verify-true
}
get-editor "P1 is left" | get-section Script | get-text-viewer | set-caret-pos 4 4
with [get-editor "P1 is left" | get-section Script | get-text-viewer] {
get-property "styleAtCaret.text" | equals "//}\n" | verify-true
get-property "styleAtCaret.fontStyle" | equals normal | verify-true
get-property "styleAtCaret.foregroundColor" | equals "#3F7F5F" | verify-true
}
get-editor "P1 is left" | get-section Script | get-text-viewer | set-caret-pos 5 28
with [get-editor "P1 is left" | get-section Script | get-text-viewer] {
get-property "styleAtCaret.text" | equals "get-tree" | verify-true
get-property "styleAtCaret.fontStyle" | equals bold | verify-true
get-property "styleAtCaret.foregroundColor" | equals "#7F0055" | verify-true
}
////////
with [get-editor "P1 is left" | get-section Script | get-text-viewer] {
set-caret-pos 4 3
select-range 4 4 3 1
key-type "M1+/"
key-type "M1+s"
}
get-editor "P1 is left" | get-section Script | get-editbox | get-property text
| equals "//with [get-view \"Q7 Explorer\" | get-tree] {\n"
+ "// get-item \"P1\"\n"
+ " \n}\n"
+ "get-view \"Q7 Explorer\" | get-tree | get-property itemCount | equals 1 | verify-true" | verify-true
------=_.content-0a7243a0-75d3-3d5f-9791-539de0e5b7ac--