This is a migrated thread and some comments may be shown as answers.

Firefox modal dialogs, Exception occured waiting for the new browser to connect

3 Answers 89 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Ron
Top achievements
Rank 1
Veteran
Ron asked on 27 Jan 2012, 10:21 AM
I've followed the instructions in the documentation on how to properly handle connecting to firefox dialogs. The documentation states to do the following:

Manager.SetNewBrowserTracking(true);

Manager.WaitForNewBrowserConnect("detail", true, 30000);

Manager.SetNewBrowserTracking(false);


The problem I'm having right now is that my test runs perfectly when opening the test in VS2010 and do a quick run. But when I selected the option "Run All Tests In Solution" in VS2010, the test fails:

Failure Information: 
~~~~~~~~~~~~~~~
Exception occured waiting for the new browser to connect.
InnerException:
System.OperationCanceledException: Exception occured waiting for the new browser to connect. ---> System.TimeoutException: Wait for condition has timed out
   at ArtOfTest.Common.WaitSync.CheckResult(WaitSync wait, String extraExceptionInfo)
   at ArtOfTest.Common.WaitSync.For[T](Predicate`1 predicate, T target, Boolean invertCondition, Int32 timeout, WaitResultType errorResultType)
   at ArtOfTest.Common.WaitSync.For[T](Predicate`1 predicate, T target, Boolean invertCondition, Int32 timeout)
   at ArtOfTest.WebAii.Core.Manager.WaitForNewBrowserConnect(String url, Boolean isPartial, Int32 timeout)
   --- End of inner exception stack trace ---
   at ArtOfTest.WebAii.Core.Manager.WaitForNewBrowserConnect(String url, Boolean isPartial, Int32 timeout)
   at ArtOfTest.WebAii.Design.IntrinsicTranslators.Descriptors.HtmlDialogHandlerDescriptor.Execute(Browser browser)
   at ArtOfTest.WebAii.Design.Extensibility.HtmlActionDescriptor.Execute(IAutomationHost autoHost)
   at ArtOfTest.WebAii.Design.Execution.ExecutionEngine.ExecuteStep(Int32 order)
------------------------------------------------------------

The same error occurs when I push this test to my teamcity build server. The error occurs in FF 9.0.1 and FF 3.6.24, but I'm guessing it fails on all Firefox versions.

3 Answers, 1 is accepted

Sort by
0
Stoich
Telerik team
answered on 01 Feb 2012, 09:58 AM
Hello Ron,
does this issue reproduce with 100% consistency on your end? While performing testing for your issue, I did notice that occasionally the Connect to pop-up window step would fail in FF for no apparent reason. I'm still working on determining the specifics of this problem but I don't seem to be able to get a reliable repro.

That being said - I was not able to link this to "Run all tests in Solution". If this issue reproduces reliably with your Test Project then the best thing might be for you to send us your project so that we may attempt to get a repro in our environment. Of course we would also need access to the app under testing so that we may actually run the test. Alternatively, you can provide a Fiddler trace:
http://tv.telerik.com/watch/automated-testing-tools/test-studio-creating-fiddler-trace
which can also be used to get a repro.

If you feel any of the requested data is too sensitive for a public forum, please go ahead and attach it in a support ticket. Our support system is 100% confidential.

One last note: a forum post (such as this one) has a response time of 72 hours. This means that we might take up to 72 hours (weekends not taken into account) in order to respond. On the other hand support tickets are treated with higher priority. Support tickets have a 24 hours response time for paying customers and 72 hours for trial users. While it might seems that it makes no difference whether a trial user post his issue in the forum or in a support ticket, in practice the support ticket would be almost guaranteed to get a quicker response.

All the best,
Stoich
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Ron
Top achievements
Rank 1
Veteran
answered on 01 Feb 2012, 11:02 AM
The problem is 100% consistent here in my test. I have noticed an error though that precedes the one mentioned in the original post. The error is 'LOG: Unexpected dialog encountered. Closing the dialog, and halting execution.'. The coded step only contains the call Manager.SetNewBrowserTracking(true);. Here is the full log:

Overall Result: Fail
------------------------------------------------------------
'1-2-2012 10:58:43' - Using .Net Runtime version: '4.0.30319.239' for tests execution.
'1-2-2012 10:58:43' - Starting execution....
'1-2-2012 10:58:45' - Detected custom code in test. Locating test assembly: WebTest.dll.
'1-2-2012 10:58:45' - Assembly Found: D:\Projects\Java\MAIN\Test\WebTest\TestResults\Ron van Pol_LAPTOP-RON-NET 2012-02-01 10_58_42\Out\WebTest.dll
'1-2-2012 10:58:45' - Loading code class: 'WebTest.MMS.Sad.Login'.
------------------------------------------------------------
------------------------------------------------------------
'1-2-2012 10:58:45' - Enabling Html Popup Tracker. Test expecting Popups.
'1-2-2012 10:58:45' - Using 'FireFox' version '3.6.25' as default browser. 
'1-2-2012 10:58:47' - 'Pass' : 1. Navigate to : '/'
'1-2-2012 10:58:48' - 'Pass' : 2. Click 'IntroJpgImage'
'1-2-2012 10:58:49' - 'Pass' : 3. Click 'NederlandsImage'
'1-2-2012 10:58:49' - 'Pass' : 4. Enter text 'invaliduser' in 'UsernameText'
'1-2-2012 10:58:49' - 'Pass' : 5. Enter text 'invalidpassword' in 'PasswordPassword'
'1-2-2012 10:58:49' - 'Pass' : 6. Click 'Submit'
'1-2-2012 10:58:49' - 'Pass' : 7. [Login_CodedStep] : @"New Coded Step
'1-2-2012 10:58:50' - LOG: Unexpected dialog encountered. Closing the dialog, and halting execution.
'1-2-2012 10:58:55' - 'Fail' : 8. Connect to modal pop-up window : ManageMent Systeem -- Webpage Dialog
------------------------------------------------------------
Failure Information: 
~~~~~~~~~~~~~~~
Exception occured waiting for the new browser to connect.
InnerException:
System.OperationCanceledException: Exception occured waiting for the new browser to connect. ---> System.TimeoutException: Wait for condition has timed out
   at ArtOfTest.Common.WaitSync.CheckResult(WaitSync wait, String extraExceptionInfo)
   at ArtOfTest.Common.WaitSync.For[T](Predicate`1 predicate, T target, Boolean invertCondition, Int32 timeout, WaitResultType errorResultType)
   at ArtOfTest.Common.WaitSync.For[T](Predicate`1 predicate, T target, Boolean invertCondition, Int32 timeout)
   at ArtOfTest.WebAii.Core.Manager.WaitForNewBrowserConnect(String url, Boolean isPartial, Int32 timeout)
   --- End of inner exception stack trace ---
   at ArtOfTest.WebAii.Core.Manager.WaitForNewBrowserConnect(String url, Boolean isPartial, Int32 timeout)
   at ArtOfTest.WebAii.Design.IntrinsicTranslators.Descriptors.HtmlDialogHandlerDescriptor.Execute(Browser browser)
   at ArtOfTest.WebAii.Design.Extensibility.HtmlActionDescriptor.Execute(IAutomationHost autoHost)
   at ArtOfTest.WebAii.Design.Execution.ExecutionEngine.ExecuteStep(Int32 order)
------------------------------------------------------------
'1-2-2012 10:58:55' - Detected a failure. Step is marked 'ContinueOnFailure=False' aborting test execution.
------------------------------------------------------------
'1-2-2012 10:58:55' - Overall Result: Fail
'1-2-2012 10:58:55' - Duration: [0 min: 9 sec: 735 msec]
------------------------------------------------------------
'1-2-2012 10:58:55' - Test completed!


0
Stoich
Telerik team
answered on 01 Feb 2012, 04:18 PM
Hi Ron,
you're probably encountering the following problem:
http://www.telerik.com/automated-testing-tools/support/documentation/user-guide/knowledge-base/dialogs-popups/unexpected-dialog-action.aspx

All the best,
Stoich
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Tags
General Discussions
Asked by
Ron
Top achievements
Rank 1
Veteran
Answers by
Stoich
Telerik team
Ron
Top achievements
Rank 1
Veteran
Share this question
or