Reputation: 2271
We have been trying to use the Acumatica Test Framework but unfortunately we are not managing to get our tests to run correctly.
We have followed the documentation step-by-step to set up the test accordingly. When we run the test, Firefox starts and the log-in page is loading correctly. The username and password are automatically entered, together with the company. The login-page completes successfully but is then resulting in an error.
The error is 'Timed out waiting for the WaitForCallbackToStart condition within the specified timeout: 500ms'
It seems that the test does not recognise that the log-in was successful. I think I managed to identify the piece of code that checks whether log-in was successful:
"try\r\n{\r\n var win = window == window.top || !window.top.frames['main'] ? window : window.top.frames['main'];\r\n if (win.document.activePanel && win.document.activePanel.getInnerWindow()) win = win.document.activePanel.getInnerWindow();\r\n if (win.px_callback && (win.px_callback.waitCallback || win.px_callback.pendingCallbacks.length)) return true;\r\n else if (win.px_all) for(var item in win.px_all) if (win.px_all[item].callback) return true;\r\n return false;\r\n}\r\ncatch (e)\r\n{\r\n if (e.message.indexOf('denied') != -1 || e.message.indexOf('cross-origin') != -1) return true;\r\n else return false;\r\n}"
This represents a JavaScript code which is executed through Selenium to identify whether the Page has loaded.
However, the above code is returning false. The Test Framework continues to periodically call this code until it returns true (or times out). In my case it never returns true and times out.
We have tried on different versions of Acumatica and also on different machines. But it always results in the same error.
I am included a screenshot of the error below.
Upvotes: 0
Views: 199
Reputation: 26
In the Visual Studio dialog in the Exception settings area set checkbox Break when this exception type is thrown equal to false and continue execution of the test. This exception is handled by Test SDK inside the LoginToDestinationSite function and you don't need to take care of it.
Upvotes: 1