blob: 838e127d85f84eedfc1ef80260040f01e0224434 [file] [log] [blame]
--- Q7 testcase ---
Format-Version: 1.0
Q7-vendor: www.xored.com/q7
Contexts: _mY5uUKEgEeKX8e34E6tWIg,_rr2EEFpSEeKcnaHGSt8OwA,_IuFcgFpZEeKcnaHGSt8OwA,_f3qEUVpSEeKcnaHGSt8OwA,_fQ0PgDsqEeOHj9Cw0T_k4Q,_ElgmoHlIEeO9Ja8zvRhhOQ
Element-Name: AndOrEnableRule
Element-Type: testcase
Element-Version: 3.0
External-Reference:
Id: _oHNjkHlTEeOByOq_5szdNw
Q7-Runtime-Version: 1.3.10.201312200736
Save-Time: 7/11/14 4:21 PM
Testcase-Type: ecl
------=_.content-0a7243a0-75d3-3d5f-9791-539de0e5b7ac
Content-Type: text/ecl
Entry-Name: .content
try {
with [get-view "Model Explorer" | get-tree] {
select "Project/View/Control dateOfBirth" | get-menu "Enable Rule" | click
select "Project/View/Control dateOfBirth/Enable Rule false" | get-menu "Or Condition" | click
select "Project/View/Control dateOfBirth/Enable Rule false/Or Condition" | get-menu "And Condition" | click
select "Project/View/Control dateOfBirth/Enable Rule false/Or Condition/And Condition" | get-menu "Leaf Condition"
| click
select "Project/View/Control dateOfBirth/Enable Rule false/Or Condition/And Condition/Leaf Condition"
| get-menu "Feature Path Domain Model Reference" | click
}
get-editor "Feature Path Domain Model Reference" | get-button "Link Domain Model EFeature" | click
with [get-window "Select a EStructuralFeature"] {
get-tree | select "name : EString"
get-button OK | click
}
get-editor "name" | close
get-editor "Leaf Condition" | get-button "Select Object" | click
with [get-window "Insert the value"] {
get-editbox
-after [get-label "The value must be parseable by the String class. For a double value please use the #.# format. For boolean values \'true\' or \'false\'."]
| set-text test
get-button OK | click
}
get-editor "Leaf Condition test" | close
get-editor "And Condition" | close
get-editor "Or Condition" | close
get-editor "Enable Rule false" | close
get-editor Player | close
get-editor View | close
with [get-view "Model Explorer" | get-tree] {
select "Project/View/Control dateOfBirth/Enable Rule false/Or Condition/And Condition" | get-menu "Leaf Condition"
| click
select "Project/View/Control dateOfBirth/Enable Rule false/Or Condition/And Condition/Leaf Condition"
| get-menu "Feature Path Domain Model Reference" | click
}
get-editor "Feature Path Domain Model Reference" | get-button "Link Domain Model EFeature" | click
with [get-window "Select a EStructuralFeature"] {
get-tree | select "isProfessional : EBoolean"
get-button OK | click
}
get-editor "isProfessional" | close
get-editor "Leaf Condition" | get-button "Select Object" | click
with [get-window "Insert the value"] {
get-editbox
-after [get-label "The value must be parseable by the Boolean class. For a double value please use the #.# format. For boolean values \'true\' or \'false\'."]
| set-text true
get-button OK | click
}
get-editor "Leaf Condition true" | close
with [get-view "Model Explorer" | get-tree] {
select "Project/View/Control dateOfBirth/Enable Rule false/Or Condition" | get-menu "And Condition" | click
select [get-item "Project/View/Control dateOfBirth/Enable Rule false/Or Condition" | get-item "And Condition"
-index 1] | get-menu "Leaf Condition" | click
select [get-item "Project/View/Control dateOfBirth/Enable Rule false/Or Condition" | get-item "And Condition"
-index 1 | get-item "Leaf Condition"] | get-menu "Feature Path Domain Model Reference" | click
}
get-editor "Feature Path Domain Model Reference" | get-button "Link Domain Model EFeature" | click
with [get-window "Select a EStructuralFeature"] {
get-tree | select "height : EDouble"
get-button OK | click
}
get-editor "height" | close
get-editor "Leaf Condition" | get-button "Select Object" | click
with [get-window "Insert the value"] {
with [get-editbox
-after [get-label "The value must be parseable by the Double class. For a double value please use the #.# format. For boolean values \'true\' or \'false\'."]] {
set-text "5.5"
}
get-button OK | click
}
get-editor "Leaf Condition 5.5" | close
get-editor "And Condition" | close
with [get-view "Model Explorer" | get-tree] {
select [get-item "Project/View/Control dateOfBirth/Enable Rule false/Or Condition" | get-item "And Condition"
-index 1] | get-menu "Leaf Condition" | click
select [get-item "Project/View/Control dateOfBirth/Enable Rule false/Or Condition" | get-item "And Condition"
-index 1 | get-item "Leaf Condition"] | get-menu "Feature Path Domain Model Reference" | click
}
get-editor "Feature Path Domain Model Reference" | get-button "Link Domain Model EFeature" | click
get-window "Select a EStructuralFeature" | get-tree | select "numberOfVictories : EInt" | double-click
get-editor "numberOfVictories" | close
get-editor "Leaf Condition" | get-button "Select Object" | click
with [get-window "Insert the value"] {
get-editbox
-after [get-label "The value must be parseable by the Integer class. For a double value please use the #.# format. For boolean values \'true\' or \'false\'."]
| set-text 6
get-button OK | click
}
get-editor "Leaf Condition 6" | close
with [get-view "Model Explorer"] {
try {
get-tree | select "Project"
get-button "Save Project" | click
} -catch {
wait 1000
try {
get-tree | select "Project"
get-button "Save Project" | click
} -catch {
wait 1000
get-tree | select "Project"
get-button "Save Project" | click
}
}
get-tree | select "Model/Player" | double-click
}
with [get-editor Player] {
get-label "No date set! Click to set date." | get-property enablement | equals false | verify-true
get-button -after [get-label "No date set! Click to set date."] | get-property enablement | equals false | verify-true
}
with [get-editor Player] {
get-button -after [get-label "Is Professional"] | check
get-editbox -after [get-label Name] | set-text test
get-editbox -after [get-label "Number Of Victories"] | click-text 1
}
with [get-editor "Player test"] {
get-label "No date set! Click to set date." | get-property enablement | equals true | verify-true
get-button -after [get-label "No date set! Click to set date."] | get-property enablement | equals true | verify-true
}
with [get-editor "Player test"] {
get-button -after [get-label "Is Professional"] | uncheck
get-editbox -after [get-label Name] | set-text ""
get-editbox -after [get-label "Number Of Victories"] | click-text 1
}
with [get-editor Player] {
get-editbox -after [get-label "Number Of Victories"] | set-text 6
get-editbox -after [get-label Height] | set-text "5.5"
get-editbox -after [get-label "Number Of Victories"] | click-text 1
}
with [get-editor Player] {
get-label "No date set! Click to set date." | get-property enablement | equals true | verify-true
get-button -after [get-label "No date set! Click to set date."] | get-property enablement | equals true | verify-true
}
with [get-editor Player] {
get-button -after [get-label "Is Professional"] | check
get-editbox -after [get-label Name] | set-text test
get-editbox -after [get-label "Number Of Victories"] | click-text 1
}
with [get-editor "Player test"] {
get-label "No date set! Click to set date." | get-property enablement | equals true | verify-true
get-button -after [get-label "No date set! Click to set date."] | get-property enablement | equals true | verify-true
}
with [get-editor "Player test"] {
get-button -after [get-label "Is Professional"] | uncheck
get-editbox -after [get-label "Number Of Victories"] | set-text 7
get-editbox -after [get-label Height] | click-text 1
}
with [get-editor "Player test"] {
get-label "No date set! Click to set date." | get-property enablement | equals false | verify-true
get-button -after [get-label "No date set! Click to set date."] | get-property enablement | equals false | verify-true
}
} -finally {
/*
get-view "Model Explorer" | get-tree | select "Project/View" | double-click
get-editor View | get-button "Delete Reference" | click
with [get-view "Model Explorer"] {
try {
get-tree | select Project
get-button "Save Project" | click
} -catch {
wait 1000
try {
get-tree | select "Project/View"
get-button "Save Project" | click
} -catch {
wait 1000
get-tree | select Project
get-button "Save Project" | click
}
}
}
*/
get-view "Model Explorer" | get-tree | select "Project/View" | get-menu "Unset Root EClass" | click
}
------=_.content-0a7243a0-75d3-3d5f-9791-539de0e5b7ac--