m2u-upass-admin / selenium-test / first-test-with-selenium-builder.json @ 138:c7659b3ef38e
History | View | Annotate | Download (4.11 KB)
1 |
{ |
---|---|
2 |
"type": "script", |
3 |
"seleniumVersion": "2", |
4 |
"formatVersion": 1, |
5 |
"steps": [
|
6 |
{ |
7 |
"type": "get", |
8 |
"url": "http://localhost:9100/m2u-upass-admin/common/Login.do" |
9 |
}, |
10 |
{ |
11 |
"type": "switchToFrameByIndex", |
12 |
"index": "0" |
13 |
}, |
14 |
{ |
15 |
"type": "setElementText", |
16 |
"locator": {
|
17 |
"type": "xpath", |
18 |
"value": "//div[2]/div[2]/form/table/tbody/tr[2]/td[3]/input" |
19 |
}, |
20 |
"text": "administrator" |
21 |
}, |
22 |
{ |
23 |
"type": "setElementText", |
24 |
"locator": {
|
25 |
"type": "xpath", |
26 |
"value": "//div[2]/div[2]/form/table/tbody/tr[3]/td[3]/input" |
27 |
}, |
28 |
"text": "Mss@dm1n" |
29 |
}, |
30 |
{ |
31 |
"type": "clickElement", |
32 |
"locator": {
|
33 |
"type": "xpath", |
34 |
"value": "//div[2]/div[2]/form/table/tbody/tr[5]/td[5]/input" |
35 |
} |
36 |
}, |
37 |
{ |
38 |
"type": "clickElement", |
39 |
"locator": {
|
40 |
"type": "xpath", |
41 |
"value": "//div[2]/div[2]/div/div[1]/div/ul/li/ul/li[1]/a" |
42 |
} |
43 |
}, |
44 |
{ |
45 |
"type": "assertTextPresent", |
46 |
"text": "No group(s) found" |
47 |
}, |
48 |
{ |
49 |
"type": "clickElement", |
50 |
"locator": {
|
51 |
"type": "xpath", |
52 |
"value": "//div[2]/div[2]/div/div[2]/div/form/div[2]/input" |
53 |
} |
54 |
}, |
55 |
{ |
56 |
"type": "clickElement", |
57 |
"locator": {
|
58 |
"type": "xpath", |
59 |
"value": "//div[2]/div[2]/div/div[2]/div/form/table/tbody/tr[2]/td[3]/input" |
60 |
} |
61 |
}, |
62 |
{ |
63 |
"type": "setElementText", |
64 |
"locator": {
|
65 |
"type": "xpath", |
66 |
"value": "//div[2]/div[2]/div/div[2]/div/form/table/tbody/tr[3]/td[3]/textarea" |
67 |
}, |
68 |
"text": "Second Group Desc" |
69 |
}, |
70 |
{ |
71 |
"type": "setElementSelected", |
72 |
"locator": {
|
73 |
"type": "xpath", |
74 |
"value": "//div[2]/div[2]/div/div[2]/div/form/table/tbody/tr[6]/td[2]/ul/li/input" |
75 |
} |
76 |
}, |
77 |
{ |
78 |
"type": "setElementText", |
79 |
"locator": {
|
80 |
"type": "xpath", |
81 |
"value": "//div[2]/div[2]/div/div[2]/div/form/table/tbody/tr[2]/td[3]/input" |
82 |
}, |
83 |
"text": "Second Group" |
84 |
}, |
85 |
{ |
86 |
"type": "sendKeysToElement", |
87 |
"locator": {
|
88 |
"type": "xpath", |
89 |
"value": "//div[2]/div[2]/div/div[2]/div/form/table/tbody/tr[3]/td[3]/textarea" |
90 |
}, |
91 |
"text": "\\9" |
92 |
}, |
93 |
{ |
94 |
"type": "clickElement", |
95 |
"locator": {
|
96 |
"type": "xpath", |
97 |
"value": "//div[2]/div[2]/div/div[2]/div/form/div/input[2]" |
98 |
} |
99 |
}, |
100 |
{ |
101 |
"type": "assertTextPresent", |
102 |
"text": "Group Second Group will be created" |
103 |
}, |
104 |
{ |
105 |
"type": "clickElement", |
106 |
"locator": {
|
107 |
"type": "xpath", |
108 |
"value": "//div[2]/div[2]/div/div[2]/div/form/div/input[2]" |
109 |
} |
110 |
}, |
111 |
{ |
112 |
"type": "assertTextPresent", |
113 |
"text": "Group Second Group has been successfully created" |
114 |
}, |
115 |
{ |
116 |
"type": "clickElement", |
117 |
"locator": {
|
118 |
"type": "xpath", |
119 |
"value": "//div[2]/div[2]/div/div[1]/div/ul/li/ul/li[1]/a" |
120 |
} |
121 |
}, |
122 |
{ |
123 |
"type": "assertTextPresent", |
124 |
"text": "Second Group" |
125 |
}, |
126 |
{ |
127 |
"type": "clickElement", |
128 |
"locator": {
|
129 |
"type": "xpath", |
130 |
"value": "//div[2]/div[2]/div/div[2]/div/form/table[2]/tbody/tr/td[1]/a" |
131 |
} |
132 |
}, |
133 |
{ |
134 |
"type": "assertTextPresent", |
135 |
"text": "Second Group Desc" |
136 |
}, |
137 |
{ |
138 |
"type": "clickElement", |
139 |
"locator": {
|
140 |
"type": "xpath", |
141 |
"value": "//div[2]/div[2]/div/div[2]/div/form/div/input[5]" |
142 |
} |
143 |
}, |
144 |
{ |
145 |
"type": "assertTextPresent", |
146 |
"text": "Group Second Group will be deleted." |
147 |
}, |
148 |
{ |
149 |
"type": "clickElement", |
150 |
"locator": {
|
151 |
"type": "xpath", |
152 |
"value": "//div[2]/div[2]/div/div[2]/div/form/div/input[2]" |
153 |
} |
154 |
}, |
155 |
{ |
156 |
"type": "assertTextPresent", |
157 |
"text": "Group Second Group has been successfully deleted" |
158 |
}, |
159 |
{ |
160 |
"type": "clickElement", |
161 |
"locator": {
|
162 |
"type": "xpath", |
163 |
"value": "//div[2]/div[2]/div/div[1]/div/ul/li/ul/li[1]/a" |
164 |
} |
165 |
}, |
166 |
{ |
167 |
"type": "assertTextPresent", |
168 |
"text": "No group(s) found" |
169 |
}, |
170 |
{ |
171 |
"type": "clickElement", |
172 |
"locator": {
|
173 |
"type": "xpath", |
174 |
"value": "//div[1]/table/tbody/tr/td[3]/a/img" |
175 |
} |
176 |
} |
177 |
] |
178 |
} |