Thomas, > > I would prefer that the output is not through divs but is returned > > directly to Selenium as strings. > > > A quick reply to this detail: Your understanding of Selenium might > be ahead of mine, but I thought the primary focus of Selenium was > interacting with the DOM. You usually trigger some browser action > and then inspect the resulting page (DOM). Therefore the divs. I > know there is this assertEval etc. infrastructure for evaluating > Javascript code, but my impression so far was it is more of an > aside and I haven't really investigated how far you could get with > it. Your suggestion would build on this infrastructure entirely.
Yes. Remote HTTP requests from Javascript were an aside until people realised how powerful they were :-) Selenium is about automating testing of an application, most of which is Javascript. Ultimately that javascript has a result in that tags and images and widgets are positioned in the DOM, but in some cases you might want to test the Javascript in ways which would be tricky with manipulation of the application. That's where automated unit testing of the Javascript comes in. Selenium can run the Javascript unit tests just as well as a manual process, so personally I would prefer that we run the tests in that way (as well as the TestRunner) as it avoids operator error and can give completely automated testing (we have that in place for our Python code at the moment). And it's very easy to add additional browser targets without being too onerous for the tester. > Another point: In my understanding, unit test do *not* return a > value. They either succeed silently or throw an exception. I think > JsUnit works this way, and we designed our unit test protocol > corresponingly (We even supported running TestRunner tests from a > JsUnit framework). If you start adding return values to your tests > you're leaving the confines of this protol and are entering a > completely new testing realm. Totally agreed. I was using return values because I was calling functions under test directly. So the wrapper function can simply fail (in the Selenium sense) and log an error. There might be some work required here to ensure that we can continue running tests and show all the failures rather than just stopping at the first hurdle. I don't know if that's possible in Selenium. Hugh ------------------------------------------------------------------------- This SF.net email is sponsored by the 2008 JavaOne(SM) Conference Don't miss this year's exciting event. There's still time to save $100. Use priority code J8TL2D2. http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone _______________________________________________ qooxdoo-devel mailing list qooxdoo-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel