Skip to content

Commit e45a0fd

Browse files
Fixes async_javascript tests for Chrome, PhantomJS and IE.
1 parent 5030a95 commit e45a0fd

File tree

1 file changed

+14
-21
lines changed

1 file changed

+14
-21
lines changed

test/acceptance/keywords/async_javascript.robot

Lines changed: 14 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -61,16 +61,13 @@ Should Be Able To Return Arrays Of Primitives From Async Scripts
6161
Length Should Be ${result} 0
6262

6363
Should Timeout If Script Does Not Invoke Callback
64-
[Documentation] Should Timeout If Script Does Not Invoke Callback
65-
Run Keyword And Expect Error
66-
... TimeoutException: Message: Timed out waiting for async script result after *
67-
... Execute Async Javascript return 1 + 2;
64+
[Documentation] Should Timeout If Script Does Not Invoke Callback
65+
Run Keyword And Expect Error TimeoutException:* Execute Async Javascript return 1 + 2;
6866

6967
Should Timeout If Script Does Not Invoke Callback With A Zero Timeout
70-
[Documentation] Should Timeout If Script Does Not Invoke Callback With A Zero Timeout
71-
Run Keyword And Expect Error
72-
... TimeoutException: Message: Timed out waiting for async script result after *
73-
... Execute Async Javascript window.setTimeout(function() {}, 0);
68+
[Documentation] Should Timeout If Script Does Not Invoke Callback With A Zero Timeout
69+
Run Keyword And Expect Error TimeoutException:* Execute Async Javascript
70+
... window.setTimeout(function() {}, 0);
7471

7572
Should Not Timeout If Script Callsback Inside A Zero Timeout
7673
[Documentation] Should Not Timeout If Script Callsback Inside A Zero Timeout
@@ -79,26 +76,22 @@ Should Not Timeout If Script Callsback Inside A Zero Timeout
7976
... window.setTimeout(function() { callback(123); }, 0)
8077

8178
Should Timeout If Script Does Not Invoke Callback With Long Timeout
82-
[Documentation] Should Timeout If Script Does Not Invoke Callback With Long Timeout
79+
[Documentation] Should Timeout If Script Does Not Invoke Callback With Long Timeout
8380
Set Selenium Timeout 0.5 seconds
84-
Run Keyword And Expect Error
85-
... TimeoutException: Message: Timed out waiting for async script result after *
86-
... Execute Async Javascript
87-
... var callback = arguments[arguments.length - 1];
88-
... window.setTimeout(callback, 1500);
81+
Run Keyword And Expect Error TimeoutException:* Execute Async Javascript
82+
... var callback = arguments[arguments.length - 1]; window.setTimeout(callback, 1500);
8983

9084
Should Detect Page Loads While Waiting On An Async Script And Return An Error
9185
[Documentation] Should Detect Page Loads While Waiting On An Async Script
9286
... And Return An Error
93-
Set Selenium Timeout 0.1 seconds
94-
Run Keyword And Expect Error
95-
... WebDriverException: Message: Detected a page unload event; async script execution does not work across page loads*
96-
... Execute Async Javascript window.location = 'javascript/dynamic';
87+
Set Selenium Timeout 0.5 seconds
88+
Run Keyword And Expect Error WebDriverException:* Execute Async Javascript
89+
... window.location = 'javascript/dynamic';
9790

9891
Should Catch Errors When Executing Initial Script
99-
[Documentation] Should Catch Errors When Executing Initial Script
100-
Run Keyword And Expect Error WebDriverException: Message: you should catch this!*
101-
... Execute Async Javascript throw Error('you should catch this!');
92+
[Documentation] Should Catch Errors When Executing Initial Script
93+
Run Keyword And Expect Error WebDriverException:* Execute Async Javascript
94+
... throw Error('you should catch this!');
10295
#TODO Implement Selenium asynchronous javascript test
10396
#Should Be Able To Execute Asynchronous Scripts
10497
# # To Do

0 commit comments

Comments
 (0)