| --- RCPTT testcase --- |
| Format-Version: 1.0 |
| Element-Name: AssertionGroupping |
| Element-Type: testcase |
| Element-Version: 3.0 |
| External-Reference: |
| Id: _GLGj8FFQEeqyG-160wAoew |
| Runtime-Version: 2.5.2.qualifier |
| Save-Time: 3/10/20 6:11 PM |
| Testcase-Type: ecl |
| |
| ------=_.description-216f885c-d591-38ce-8ea2-e4f8cb4d6ffa |
| Content-Type: text/plain |
| Entry-Name: .description |
| |
| Copyright (c) 2020 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 v2.0 |
| which accompanies this distribution, and is available at |
| https://www.eclipse.org/legal/epl-v20.html |
| |
| Contributors: |
| Xored Software Inc - initial creation and/or initial documentation |
| -------------------------------------------------------------------------------- |
| |
| Test Steps: |
| 1. Create test for self-aut |
| 2. Add to created test script with variables defenition |
| 3. Start asserting selfQ7 |
| 4. Assert columns in expressions table |
| 5. Check if generate correct code with grouping by item |
| 6. Remove all expressions |
| 7. Start asserting selfQ7 |
| 8. Assert Edit menu |
| 9. Check if generated code with grouping by menu |
| ------=_.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 | get-menu -path "New/RCP Testing Tool Project" | click |
| with [get-window "New Project"] { |
| with [get-editbox -after [get-label "Project name:"]] { |
| set-text test |
| } |
| get-button Finish | click |
| } |
| get-view "Test Explorer" | get-tree | select test | get-menu -path "New/Test Case" | click |
| with [get-window "New Test Case"] { |
| get-editbox -after [get-label "Name:"] | set-text t2 |
| get-button Finish | click |
| } |
| with [get-editor t2 | get-section Script | get-text-viewer] { |
| set-text "get-button \"Open Perspective\" | click\n" + |
| "get-window \"Open Perspective\" | get-table | select Debug | double-click\n" + |
| "with [get-view Expressions] {\n" + |
| "click\n" + |
| "with [get-tree] {\n" + |
| "select \"Add new expression\" | activate-cell-edit -type MouseClickSelection\n" + |
| "with [get-editbox] {\n" + |
| "set-text 123\n" + |
| "key-type Enter\n" + |
| "}\n" + |
| "apply-cell-edit -deactivate\n" + |
| "select \"Add new expression\" | activate-cell-edit -type MouseClickSelection\n" + |
| "with [get-editbox] {\n" + |
| "set-text 456\n" + |
| "key-type Enter\n" + |
| "}\n" + |
| "apply-cell-edit -deactivate\n" + |
| "}\n" + |
| "}\n" |
| } |
| |
| get-editor t2 | get-button Record | click |
| |
| with [get-window "Control Panel - t2 (test) - selfQ7 [Recording]"] { |
| get-button "Switch to Recording Mode" | click |
| get-button "Switch to Assertion Mode" | click |
| } |
| |
| get-aut selfQ7 | eval { |
| with [get-view Expressions | get-tree] { |
| get-item -path "\"123\"" | click |
| } |
| } |
| |
| with [get-window "Control Panel - t2 (test) - selfQ7 [Asserting]"] { |
| with [get-window "Assertion and Verification"] { |
| get-tree | get-item -path "TreeItem \\(Basic Properties\\)/columns" | expand |
| get-tree | get-item -path "TreeItem \\(Basic Properties\\)/columns" | check |
| get-button Add | click |
| } |
| } |
| |
| get-aut selfQ7 | eval { |
| with [get-view Expressions | get-tree] { |
| get-item -path "\"456\"" | click |
| } |
| } |
| |
| with [get-window "Control Panel - t2 (test) - selfQ7 [Asserting]"] { |
| with [get-window "Assertion and Verification"] { |
| get-tree | get-item -path "TreeItem \\(Basic Properties\\)/columns" | expand |
| get-tree | get-item -path "TreeItem \\(Basic Properties\\)/columns" | check |
| get-button Add | click |
| } |
| } |
| |
| |
| with [get-window "Control Panel - t2 (test) - selfQ7 [Asserting]"] { |
| get-text-viewer | get-property text |
| | contains "with [get-view Expressions | get-tree] {\n" |
| + " with [get-item -path \"\\\"123\\\"\"] {\n" |
| + " get-property \"columns[0]\" | equals \"\\\"123\\\"\" | verify-true\n" |
| + " get-property \"columns[1]\" | equals \"\" | verify-true\n" |
| + " }\n" |
| + " with [get-item -path \"\\\"456\\\"\"] {\n" |
| + " get-property \"columns[0]\" | equals \"\\\"456\\\"\" | verify-true\n" |
| + " get-property \"columns[1]\" | equals \"\" | verify-true\n" |
| + " }\n" |
| + "}" | verify-true |
| get-button "Switch to Recording Mode" | click |
| } |
| |
| get-aut selfQ7 | eval { |
| get-button "Remove All Expressions" | click |
| get-window "Remove All Expressions" | get-button Yes | click |
| } |
| |
| with [get-window "Control Panel - t2 (test) - selfQ7 [Recording]"] { |
| get-button "Switch to Recording Mode" | click |
| get-button "Switch to Assertion Mode" | click |
| } |
| |
| get-aut selfQ7 | eval { |
| get-menu -path "Edit" | click |
| } |
| with [get-window "Control Panel - t2 (test) - selfQ7 [Asserting]" | get-window "Assertion and Verification"] { |
| get-tree | get-item -path "MenuItem \\(Basic Properties\\)/caption" | check |
| get-button Add | click |
| } |
| |
| get-aut selfQ7 | eval { |
| get-menu -path "Edit" | click |
| } |
| with [get-window "Control Panel - t2 (test) - selfQ7 [Asserting]" | get-window "Assertion and Verification"] { |
| get-tree | get-item -path "MenuItem \\(Basic Properties\\)/index" | check |
| get-button Add | click |
| } |
| get-window "Control Panel - t2 (test) - selfQ7 [Asserting]" | get-text-viewer | get-property text |
| | contains "with [get-menu -path Edit] {\n" |
| + " get-property caption | equals \"&Edit\" | verify-true\n" |
| + " get-property index | equals 1 | verify-true\n" |
| + "}" | verify-true |
| ------=_.content-0a7243a0-75d3-3d5f-9791-539de0e5b7ac-- |