-
20 May 2008 2:05 AM #1
Testing Ext js application with Selenium RC
Testing Ext js application with Selenium RC
Can anyone tell me, how to get the ID from data store / source to test with Selenium RC. Is this possible for acceptance testing with ext js thru selenium RC
-
21 May 2008 12:35 PM #2
Try:
That will evalulate the JS line and store it into the Selenium variable 'storeId' or whatever you want to use.Code:storeEval( 'selenium.page().currentWindow.Path.To.Your.DataStore.id', 'storeId' )
To use the value in a Selenium command (i think, its been awhile):
or if using Javacript:Code:type( someInputElement, "My data store Id is $storeId" )
Code:type( someInputElement, javascript{"My data store Id is " + storedVars['storeId']} )
-
2 Jun 2008 11:06 PM #3
Thanks CableDawg
But i am using phpunit for UI test, when i use firefox selenium IDE, its generating id's randomly for the drop down list click event... mainly the ID changes every time.. because its from data store to the drop downlist...
Please look at the sample below.... and let me know how to handle this...
$this->click("ext-gen372");
-
20 Jun 2008 7:11 AM #4
hi
If you are using EXTJS, when you record a random id will be generated, which keeps change each every time, so we have to use XPath, for the extjs elements, to find the Xpath there are 2 Firefox add on, one is firebug and Xpather,
thanks
-- Faisal
-
4 Mar 2009 7:35 PM #5
How we test Ext from Java with Selenium
How we test Ext from Java with Selenium
I just wrote an article on how I've been testing an ExtJS GUI in Java at:
http://www.neocoders.com/portal/arti...nium-and-extjs
Primarily, it describes how I got around having to assign hand-crafted IDs to all the Ext components, and also a little bit on sychronising the tests with AJAX. It's a work in progress, and any comments or requests for clarification are welcome.
cheers,
Lindsay
-
24 May 2011 11:20 AM #6
-
22 Dec 2011 4:18 PM #7
you can check this article
http://techblog.outbrain.com/2011/12/how-to-outbrain-selenium-tests-with-ext-framework/
-
22 Dec 2011 10:30 PM #8
-
3 Jan 2012 6:23 AM #9
i believe that i release it in the next two weeks.
we are testing it on our system and it is look fine.
if you you want the code as, is please let me know
-
12 Sep 2012 5:34 AM #10
You may want to look at RIATest.
Version 5.0 fully supports ExtJS testing. ExtJS UI widgets are first class citizen in RIATest. This means that unlike other HTML testing tools you do not need to struggle with dynamic ids. The tests in RIATest operate in terms of ExtJS UI widgets.
Examples of RIATest scripts that work with ExtJS widgets:
The following clicks on an ExtJS button with label "Next Page":
And the following does drag-n-drop of a row from one ExtJS tree to another:PHP Code:ExtButton("Next Page")=>click();
And this collapses the header of an ExtJS box:PHP Code:ExtRow("Controller.js")=>dragAndDropTo(ExtTreePanel("#tree2")->ExtRow("Custom Ext JS"));
(All sample code above is from real test scripts that run on ExtJS sample applications).PHP Code:ExtBox("Feeds")->ExtHeader("FeedsВ")->ExtCollapser()=>click();
RIATest also knows when to automatically wait for ExtJS AJAX to finish, so if your UI does dynamic content downloading the tests will auto-magically wait until data is received from server.
(Disclaimer: I am a RIATest team member).


Reply With Quote