-
1. Selenium - unconditioned A4J-WAIT
lfryc Mar 22, 2011 9:31 AM (in response to oliverg)Hi Oliver,
I encourage you to use richfaces-selenium library (the API is moreless compatible to newly started project Arquillian Ajocado, so it will help you migrate to this new cool framework in future ;-)
Look for RequestTypeGuard in documentation link you have posted [1], I think it is what you are looking for.
[1] http://community.jboss.org/wiki/RichFaces-SeleniumLibrary
RequestTypeGuard intercepts each XMLHttpRequest and waits for it's completion - it means it waits for end of COMPLETED phase of XHR request in which is rendering done - the solution was developed for testing of RichFaces itself. ;-)
-
2. Selenium - unconditioned A4J-WAIT
oliverg Mar 23, 2011 2:24 PM (in response to lfryc)Hi Lukas,
thanks a lot!
I will check, if I can let inherit the super class for our Selenium-Tests from AbstractTestCase of richfaces-selenium after refactoring a bit.
BTW: I looked at initializeBrowser() with the @BeforeClass-Annotation in AbstractTestCase and saw that the selenium instance will be initialized every time there. What do you think is the best way, if I want a single initialization (+ login) for all my test classes (maybe in a test-suite) -- Overwrite initializeBrowser() in own super class for the tests (which holds e.g. something like a initialized-flag)?
-
3. Selenium - unconditioned A4J-WAIT
lfryc Mar 24, 2011 5:57 AM (in response to oliverg)1 of 1 people found this helpfulHi Oliver,
I discourage you to use single initialization point (like login before suite) - it makes tests to be not separated and fragile.
Say your test will make user session to fail and login user will not be able to reuse session that is already started.
It makes the rest of test suite to fail.
But if you will use the session-per-class principle as it is now, only one test class will fail.