Explorar el Código

[fix] gecko driver cannot detect the page load finish on preferences form submit. It now works with this dirty workaround..

Adam Tauber hace 8 años
padre
commit
629fa4355a
Se han modificado 1 ficheros con 20 adiciones y 24 borrados
  1. 20
    24
      tests/robot/test_basic.robot

+ 20
- 24
tests/robot/test_basic.robot Ver fichero

4
 Test Teardown   Close All Browsers
4
 Test Teardown   Close All Browsers
5
 
5
 
6
 
6
 
7
+*** Keywords ***
8
+Submit Preferences
9
+    Set Selenium Speed  2 seconds
10
+    Submit Form  id=search_form
11
+    Location Should Be  http://localhost:11111/
12
+    Set Selenium Speed  0 seconds
13
+
14
+
7
 *** Test Cases ***
15
 *** Test Cases ***
8
 Front page
16
 Front page
9
     Page Should Contain  about
17
     Page Should Contain  about
33
     Page Should Contain Checkbox  category_dummy
41
     Page Should Contain Checkbox  category_dummy
34
     Click Element  xpath=//*[.="general"]
42
     Click Element  xpath=//*[.="general"]
35
     Click Element  xpath=//*[.="dummy"]
43
     Click Element  xpath=//*[.="dummy"]
36
-    Submit Form  id=search_form
37
-    Location Should Be  http://localhost:11111/
44
+    Submit Preferences
38
     Checkbox Should Not Be Selected  category_general
45
     Checkbox Should Not Be Selected  category_general
39
     Checkbox Should Be Selected  category_dummy
46
     Checkbox Should Be Selected  category_dummy
40
 
47
 
43
     Page Should Contain  preferences
50
     Page Should Contain  preferences
44
     Go To  http://localhost:11111/preferences
51
     Go To  http://localhost:11111/preferences
45
     Select From List  locale  hu
52
     Select From List  locale  hu
46
-    Submit Form  id=search_form
47
-    Location Should Be  http://localhost:11111/
53
+    Submit Preferences
48
     Page Should Contain  rólunk
54
     Page Should Contain  rólunk
49
     Page Should Contain  beállítások
55
     Page Should Contain  beállítások
50
 
56
 
53
     Page Should Contain  preferences
59
     Page Should Contain  preferences
54
     Go To  http://localhost:11111/preferences
60
     Go To  http://localhost:11111/preferences
55
     Select From List  method  GET
61
     Select From List  method  GET
56
-    Submit Form  id=search_form
57
-    Location Should Be  http://localhost:11111/
62
+    Submit Preferences
58
     Go To  http://localhost:11111/preferences
63
     Go To  http://localhost:11111/preferences
59
     List Selection Should Be  method  GET
64
     List Selection Should Be  method  GET
60
     Select From List  method  POST
65
     Select From List  method  POST
61
-    Submit Form  id=search_form
62
-    Location Should Be  http://localhost:11111/
66
+    Submit Preferences
63
     Go To  http://localhost:11111/preferences
67
     Go To  http://localhost:11111/preferences
64
     List Selection Should Be  method  POST
68
     List Selection Should Be  method  POST
65
 
69
 
69
     Go To  http://localhost:11111/preferences
73
     Go To  http://localhost:11111/preferences
70
     List Selection Should Be  theme  legacy
74
     List Selection Should Be  theme  legacy
71
     Select From List  theme  oscar
75
     Select From List  theme  oscar
72
-    Submit Form  id=search_form
73
-    Location Should Be  http://localhost:11111/
76
+    Submit Preferences
74
     Go To  http://localhost:11111/preferences
77
     Go To  http://localhost:11111/preferences
75
     List Selection Should Be  theme  oscar
78
     List Selection Should Be  theme  oscar
76
 
79
 
80
     Go To  http://localhost:11111/preferences
83
     Go To  http://localhost:11111/preferences
81
     List Selection Should Be  safesearch  None
84
     List Selection Should Be  safesearch  None
82
     Select From List  safesearch  Strict
85
     Select From List  safesearch  Strict
83
-    Submit Form  id=search_form
84
-    Location Should Be  http://localhost:11111/
86
+    Submit Preferences
85
     Go To  http://localhost:11111/preferences
87
     Go To  http://localhost:11111/preferences
86
     List Selection Should Be  safesearch  Strict
88
     List Selection Should Be  safesearch  Strict
87
 
89
 
91
     Go To  http://localhost:11111/preferences
93
     Go To  http://localhost:11111/preferences
92
     List Selection Should Be  image_proxy  Disabled
94
     List Selection Should Be  image_proxy  Disabled
93
     Select From List  image_proxy  Enabled
95
     Select From List  image_proxy  Enabled
94
-    Submit Form  id=search_form
95
-    Location Should Be  http://localhost:11111/
96
+    Submit Preferences
96
     Go To  http://localhost:11111/preferences
97
     Go To  http://localhost:11111/preferences
97
     List Selection Should Be  image_proxy  Enabled
98
     List Selection Should Be  image_proxy  Enabled
98
 
99
 
102
     Go To  http://localhost:11111/preferences
103
     Go To  http://localhost:11111/preferences
103
     List Selection Should Be  language  Automatic
104
     List Selection Should Be  language  Automatic
104
     Select From List  language  Turkish (Turkey) - tr_TR
105
     Select From List  language  Turkish (Turkey) - tr_TR
105
-    Submit Form  id=search_form
106
-    Location Should Be  http://localhost:11111/
106
+    Submit Preferences
107
     Go To  http://localhost:11111/preferences
107
     Go To  http://localhost:11111/preferences
108
     List Selection Should Be  language  Turkish (Turkey) - tr_TR
108
     List Selection Should Be  language  Turkish (Turkey) - tr_TR
109
 
109
 
113
     Go To  http://localhost:11111/preferences
113
     Go To  http://localhost:11111/preferences
114
     List Selection Should Be  autocomplete  -
114
     List Selection Should Be  autocomplete  -
115
     Select From List  autocomplete  google
115
     Select From List  autocomplete  google
116
-    Submit Form  id=search_form
117
-    Location Should Be  http://localhost:11111/
116
+    Submit Preferences
118
     Go To  http://localhost:11111/preferences
117
     Go To  http://localhost:11111/preferences
119
     List Selection Should Be  autocomplete  google
118
     List Selection Should Be  autocomplete  google
120
 
119
 
126
     Element Should Contain  xpath=//label[@class="deny"][@for='engine_dummy_dummy_dummy']  Block
125
     Element Should Contain  xpath=//label[@class="deny"][@for='engine_dummy_dummy_dummy']  Block
127
     Element Should Contain  xpath=//label[@class="deny"][@for='engine_general_general_dummy']  Block
126
     Element Should Contain  xpath=//label[@class="deny"][@for='engine_general_general_dummy']  Block
128
     Click Element  xpath=//label[@class="deny"][@for='engine_general_general_dummy']
127
     Click Element  xpath=//label[@class="deny"][@for='engine_general_general_dummy']
129
-    Submit Form  id=search_form
130
-    Location Should Be  http://localhost:11111/
128
+    Submit Preferences
131
     Page Should Contain  about
129
     Page Should Contain  about
132
     Page Should Contain  preferences
130
     Page Should Contain  preferences
133
     Go To  http://localhost:11111/preferences
131
     Go To  http://localhost:11111/preferences
141
     Go To  http://localhost:11111/preferences
139
     Go To  http://localhost:11111/preferences
142
     List Selection Should Be  theme  legacy
140
     List Selection Should Be  theme  legacy
143
     Select From List  theme  oscar
141
     Select From List  theme  oscar
144
-    Submit Form  id=search_form
145
-    Location Should Be  http://localhost:11111/
142
+    Submit Preferences
146
     Go To  http://localhost:11111/preferences
143
     Go To  http://localhost:11111/preferences
147
     List Selection Should Be  theme  oscar
144
     List Selection Should Be  theme  oscar
148
     Page Should Contain  Plugins
145
     Page Should Contain  Plugins
149
     Click Link  Plugins
146
     Click Link  Plugins
150
     Checkbox Should Not Be Selected  id=plugin_HTTPS_rewrite
147
     Checkbox Should Not Be Selected  id=plugin_HTTPS_rewrite
151
     Click Element  xpath=//label[@for='plugin_HTTPS_rewrite']
148
     Click Element  xpath=//label[@for='plugin_HTTPS_rewrite']
152
-    Submit Form  id=search_form
153
-    Location Should Be  http://localhost:11111/
149
+    Submit Preferences
154
     Go To  http://localhost:11111/preferences
150
     Go To  http://localhost:11111/preferences
155
     Page Should Contain  Plugins
151
     Page Should Contain  Plugins
156
     Click Link  Plugins
152
     Click Link  Plugins