You may want to try adding a waitForElementPresent command to your user extensions.
See for details: http://lists.public.thoughtworks.org/pipermail/selenium-users/2005-June/000669.html

You could then have your test wait for the new element to appear.
Of course, if it never appears, then the test will hang (until someone gets around to forcing all of our
WaitFor and AndWait commands to automatically time out after a set time).

I am in the middle of generalising some of the command and assertion generation.  When finished,
you will have several "waitFor" commands available such as waitForElementPresent.
Unfortunately I will not be able to do much work on this for a few weeks
(anyone else out there willing to take over on this task is welcome too :-)

David Kemp
ThoughtWorks Australia Pty Ltd
http://www.thoughtworks.com


[EMAIL PROTECTED] wrote on 10/09/2005 11:22:14 AM:

> So apparently the reason selenium was not seeing my DOM changes was
> that selenium uses _javascript_'s asynchronous event dispatch. So my DOM
> changes were being made, just not quickly enough for the asserts() to
> behave as expected.
>
> I am new to _javascript_; as near as I can tell from experience and from
> research, synthetic JS events sent via dispatchEvent() are
> asynchronous. Since selenium relies on such synthetic events, its
> value is limited when constructing tests such as the one I attempted.
> Is there an alternative way to dispatch events synchronously?
> Integrating synchronous events into Selenium would make it *much* more
> useful, IMO. I know there are the various *AndWait() actions, but
> those are designed for a narrow purpose - waiting for the page to reload.
>
> - Rick_______________________________________________
> Selenium-users mailing list
> Selenium-users@lists.public.thoughtworks.org
> http://lists.public.thoughtworks.org/mailman/listinfo/selenium-users
_______________________________________________
Selenium-users mailing list
Selenium-users@lists.public.thoughtworks.org
http://lists.public.thoughtworks.org/mailman/listinfo/selenium-users

Reply via email to