-
Notifications
You must be signed in to change notification settings - Fork 3
/
Coverage.test
51 lines (49 loc) · 3.03 KB
/
Coverage.test
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
--- RCPTT testcase ---
Format-Version: 1.0
Contexts: _Ki1iALN7Ee2kZdZD_a54_g,_Ayow4KrpEeqpkej7GeVvKQ
Element-Name: Coverage
Element-Type: testcase
Element-Version: 3.0
External-Reference:
Id: _PWwSELN9Ee2kZdZD_a54_g
Runtime-Version: 2.5.4.202210020716
Save-Time: 11/30/23, 5:39 PM
Testcase-Type: ecl
------=_.content-0a7243a0-75d3-3d5f-9791-539de0e5b7ac
Content-Type: text/ecl
Entry-Name: .content
get-view "Package Explorer" | get-tree | select "test/generated/profiling.mtlp" | double-click
with [get-editor "profiling.mtlp" | get-tree] {
get-item
-path "platform:\\/resource\\/test\\/generated\\/profiling.mtlp/Profile Resource/100% \\/ 8ms \\/ 1 times Module \\[Module test\\]/100% \\/ 8ms \\/ 1 times Template \\[template myTemplate\\(ecore::EPackage\\)\\]/100% \\/ 8ms \\/ 1 times FileStatement \\[myParam.name \\+ '.txt'\\]/75% \\/ 6ms \\/ 1 times ForStatement \\[myVariable1 : ecore::EClassifier | myParam.eClassifiers\\]/62,5% \\/ 5ms \\/ 23 times Expression \\[myVariable1.myOtherTemplate\\(\\)\\]"
| double-click
}
get-editor "test.mtl" | get-text-viewer | get-property "getSelectionText()" | equals "myVariable1.myOtherTemplate()"
| verify-true
with [get-editor "test.mtl" | get-text-viewer] {
get-property "styles[15].text" | equals "[template" | verify-true
get-property "styles[15].backgroundColor" | equals "#C0FFC0" | verify-true
get-property "styles[59].text" | equals "[/template]" | verify-true
get-property "styles[59].backgroundColor" | equals "#C0FFC0" | verify-true
}
with [get-editor "profiling.mtlp"] {
click
with [get-tree] {
select "platform:\\/resource\\/test\\/generated\\/profiling.mtlp/Profile Resource/100% \\/ 8ms \\/ 1 times Module \\[Module test\\]/100% \\/ 8ms \\/ 1 times Template \\[template myTemplate\\(ecore::EPackage\\)\\]/100% \\/ 8ms \\/ 1 times FileStatement \\[myParam.name \\+ '.txt'\\]/75% \\/ 6ms \\/ 1 times ForStatement \\[myVariable1 : ecore::EClassifier | myParam.eClassifiers\\]/62,5% \\/ 5ms \\/ 23 times Expression \\[myVariable1.myOtherTemplate\\(\\)\\]/25% \\/ 2ms \\/ 23 times Template \\[template myOtherTemplate\\(ecore::EClassifier\\)\\]"
| double-click
}
}
with [get-editor "otherModule.mtl" | get-text-viewer] {
get-property "getSelectionText()" | equals "[template public myOtherTemplate(myParam : ecore::EClassifier)]\n"
+ " [myParam.name/].\n"
+ "[/template]" | verify-true
get-property "styles[6].text" | equals "[template" | verify-true
get-property "styles[6].backgroundColor" | equals "#C0FFC0" | verify-true
get-property "styles[22].text" | equals "[/template]" | verify-true
get-property "styles[22].backgroundColor" | equals "#C0FFC0" | verify-true
get-property "styles[25].text" | equals "[template" | verify-true
get-property "styles[25].backgroundColor" | equals "#FFA0A0" | verify-true
get-property "styles[41].text" | equals "[/template]" | verify-true
get-property "styles[41].backgroundColor" | equals "#FFA0A0" | verify-true
}
------=_.content-0a7243a0-75d3-3d5f-9791-539de0e5b7ac--