Thanks for all the help so far, I think I'm getting closer to finding
the issue here. It seems I'm suffering from three issues.

The first, isElementPresent is still throwing exceptions (I deleted my
local maven cache and so should have the lastest version)

The second, strange behaviour with grouping and using the
TelluriumApi, my test fails in a different place depending on the
value of the group attribute. See comments in test script below.

// Model
ui.Container(uid: "mainnav", clocator: [tag: "div", 'class':
"mainMenu"], group: true) {
    UrlLink(uid: "events", clocator: [text: "Events"])
    UrlLink(uid: "suppliers", clocator: [text: "Suppliers"])
    UrlLink(uid: "venues", clocator: [text: "Venues"])
    UrlLink(uid: "bookingReport", clocator: [text: "Booking Report"])
    UrlLink(uid: "notifications", clocator: [text: "Notifications"])
    UrlLink(uid: "help", clocator: [text: "Help"])
}

click "welcomePage.xEventLink"
waitForPageToLoad 10000
assertTrue("Did not find main menu", isElementPresent("mainnav")) //
Exception is thrown by isElementPresent on this line when group: true,
useTelluriumApi(true)
click "mainnav.suppliers" // Test fails on this line when group:
false, useTelluriumApi(true)
waitForPageToLoad 20000
assertTrue(isElementPresent("supplierList"))

Third problem, using useTelluriumApi(false) I get past the above test
script but then fail when I click on something that is not a regular
link. I'm clicking on an <input type="button"> which uses javascript
to submit a form. In this case waitForPageToLoad is returning before
the form is even submitted. I don't have any official time to look
into when this behaviour changed but this wasn't a problem in snapshot
0.7.0-20091226.045110-19. Is this a case where I'm going to have to
update my test code? Or should this work as it did before?

Thanks again for all your help.

On 4 February 2010 02:14, Jian Fang <[email protected]> wrote:
>
> waitForPageLoad is actually delegated to Selenium in the new Engine API and
> seems I could not re-produce your problem.
>
> Could you check out Tellurium trunk/core project and run the test
> GoogleSearchJUnitTestCase to see if you can see the same behavior for
> waitForPageLoad?
>
> Thanks,
>
> Jian
>
>
> On Wed, Feb 3, 2010 at 5:06 PM, Jian Fang <[email protected]> wrote:
>>
>> Hi,
>>
>> The isElementPresent() in new Tellurium API has been fixed. Please update
>> artifacts from Tellurium Maven repo.
>>
>> I am looking into the waitForPageLoad problem now.
>>
>> Thanks,
>>
>> Jian
>>
>> On Wed, Feb 3, 2010 at 10:09 AM, Jian Fang <[email protected]>
>> wrote:
>>>
>>> BTW, could I ask you for a favor? I like to use your html source in our
>>> user guide document since
>>> it is a very good example for the Repeat object.
>>>
>>> Thanks in advance,
>>>
>>> Jian
>>>
>>> On Wed, Feb 3, 2010 at 10:06 AM, Jian Fang <[email protected]>
>>> wrote:
>>>>
>>>> The Repeat object inherits the Container object and it does not include
>>>> UI templates. You can use it just like a Container. The
>>>> difference is that you should use index to refer to a Repeat object.
>>>>
>>>> Here is the UI module I created for the html you provided.
>>>>
>>>>     ui.Form(uid: "SailingForm", clocator: [name: "selectedSailingsForm"]
>>>> ){
>>>>       Repeat(uid: "Section", clocator: [tag: "div", class: "segment
>>>> clearfix"]){
>>>>         Repeat(uid: "Option", clocator: [tag: "div", class: "option",
>>>> direct: "true"]){
>>>>           List(uid: "Fares", clocator: [tag: "ul", class: "fares",
>>>> direct: "true"], separator: "li"){
>>>>             Container(uid: "all"){
>>>>                 RadioButton(uid: "radio", clocator: [:], respond:
>>>> ["click"])
>>>>                 TextBox(uid: "label", clocator: [tag: "label"])
>>>>             }
>>>>           }
>>>>           Container(uid: "Details", clocator: [tag: "div", class:
>>>> "details"]){
>>>>             Container(uid: "ShipInfo", clocator: [tag: "dl"]){
>>>>               TextBox(uid: "ShipLabel", clocator: [tag: "dt", position:
>>>> "1"])
>>>>               TextBox(uid: "Ship", clocator: [tag: "dd", position: "1"])
>>>>               TextBox(uid: "DepartureLabel", clocator: [tag: "dt",
>>>> position: "2"])
>>>>               Container(uid: "Departure", clocator: [tag: "dd",
>>>> position: "2"]){
>>>>                 TextBox(uid: "Time", clocator: [tag: "em"])
>>>>               }
>>>>               TextBox(uid: "ArrivalLabel", clocator: [tag: "dt",
>>>> position: "3"])
>>>>               Container(uid: "Arrival", clocator: [tag: "dd", position:
>>>> "3"]){
>>>>                 TextBox(uid: "Time", clocator: [tag: "em"])
>>>>               }
>>>>             }
>>>>           }
>>>>         }
>>>>       }
>>>>     }
>>>>
>>>> and the test case is shown as follows,
>>>>
>>>>     @Test
>>>>     public void testRepeat(){
>>>>         connect("JForm");
>>>> //        useCssSelector(true);            //uncomment this line if you
>>>> choose to use css selector
>>>>         int num = jlm.getRepeatNum("SailingForm.Section");
>>>>         assertEquals(2, num);
>>>>         num = jlm.getRepeatNum("SailingForm.Section[1].Option");
>>>>         assertEquals(2, num);
>>>>         int size =
>>>> jlm.getListSize("SailingForm.Section[1].Option[1].Fares");
>>>>         assertEquals(2, size);
>>>>         String ship =
>>>> jlm.getText("SailingForm.Section[1].Option[1].Details.ShipInfo.Ship");
>>>>         assertEquals("A", ship);
>>>>         String departureTime =
>>>> jlm.getText("SailingForm.Section[1].Option[1].Details.ShipInfo.Departure.Time");
>>>>         assertEquals("08:00", departureTime);
>>>>         String arrivalTime =
>>>> jlm.getText("SailingForm.Section[1].Option[1].Details.ShipInfo.Arrival.Time");
>>>>         assertEquals("11:45", arrivalTime);
>>>>     }
>>>>
>>>> As you notice, the Repeat object has one additional method
>>>>
>>>> int getRepeatNum(String uid)
>>>>
>>>> to get back the number of repeated objects.
>>>>
>>>> Thanks,
>>>>
>>>> Jian
>>>>
>>>> On Wed, Feb 3, 2010 at 10:00 AM, Jian Fang <[email protected]>
>>>> wrote:
>>>>>
>>>>> Hi there,
>>>>>
>>>>> I just checked in the Repeat object to Core.
>>>>>
>>>>> You can update your project from our Maven repo or download them
>>>>> directly from
>>>>>
>>>>>
>>>>> http://maven.kungfuters.org/content/repositories/snapshots/org/seleniumhq/selenium/server/selenium-server/1.0.1-te2-SNAPSHOT/selenium-server-1.0.1-te2-20100203.144532-2.jar
>>>>>
>>>>>
>>>>> http://maven.kungfuters.org/content/repositories/snapshots/org/telluriumsource/tellurium-core/0.7.0-SNAPSHOT/tellurium-core-0.7.0-20100203.145844-77.jar
>>>>>
>>>>> The Repeat object is more elegant way to solve your problem.
>>>>>
>>>>> I will post my test code soon.
>>>>>
>>>>> Thanks,
>>>>>
>>>>> Jian
>>>>>
>>>>> On Wed, Feb 3, 2010 at 9:01 AM, Jian Fang <[email protected]>
>>>>> wrote:
>>>>>>
>>>>>> Seems to be the new Tellurium API problem. Most Tellurium APIs have
>>>>>> the
>>>>>> same interface with Selenium APIs but with a different implementation,
>>>>>> i.e, implemented
>>>>>> using jQuery. I haven't tested all of them. I will look into this
>>>>>> problem.
>>>>>>
>>>>>> For the timebeing, you can simply call useTelluriumApi(false), the
>>>>>> core will switch back
>>>>>> to Selenium APIs. The switch happens under the hood and you don't need
>>>>>> to change your
>>>>>> test code unless you call some APIs that only exist in Tellurium.
>>>>>>
>>>>>> Thanks,
>>>>>>
>>>>>> Jian
>>>>>>
>>>>>> On Wed, Feb 3, 2010 at 4:54 AM, Jonathan Share <[email protected]>
>>>>>> wrote:
>>>>>>>
>>>>>>> On 2 February 2010 17:45, Jian Fang <[email protected]> wrote:
>>>>>>> > I will look into the isElementPresent() problem. Are you using new
>>>>>>> > Tellurium
>>>>>>> > API?
>>>>>>>
>>>>>>> No, I just tried to add a call to useTelluriumApi(true) and after
>>>>>>> that
>>>>>>> change my test case was no longer able to click on links (test code
>>>>>>> continued but no interaction happened with the web page)
>>>>>>>
>>>>>>> >
>>>>>>> > What do you mean "waitForPageToLoad doesn't seem to be working
>>>>>>> > fine"?, it
>>>>>>> > just returned
>>>>>>> > without waiting? What was the behavior?
>>>>>>>
>>>>>>> I mean that it appears to be returning before the page is finished
>>>>>>> loading... if I call waitForElementPresent for something that should
>>>>>>> be there immediately after page load (no dynamic javascript) then it
>>>>>>> fails the first time it tests for the element (causing a screenshot
>>>>>>> to
>>>>>>> be taken) but then on the second attempt to test for the element it
>>>>>>> finds it and returns true.
>>>>>>>
>>>>>>> >
>>>>>>> > Thanks,
>>>>>>> >
>>>>>>> > Jian
>>>>>>> >
>>>>>>> > On Tue, Feb 2, 2010 at 11:24 AM, Jonathan Share
>>>>>>> > <[email protected]> wrote:
>>>>>>> >>
>>>>>>> >> Thanks, I have a small test case working using lists, however now
>>>>>>> >> that
>>>>>>> >> I've updated to the current snapshot again I'm seeing a couple of
>>>>>>> >> new
>>>>>>> >> problems. isElementPresent() is throwing an exception when the
>>>>>>> >> element
>>>>>>> >> doesn't exist (instead of returning false) and waitForPageToLoad
>>>>>>> >> doesn't seem to be working fine... for example, the following code
>>>>>>> >> that worked on an older snapshot
>>>>>>> >>
>>>>>>> >>    public void login(String username, String password) {
>>>>>>> >>        type "login.username", username
>>>>>>> >>        type "login.password", password
>>>>>>> >>        click "login.submit"
>>>>>>> >>        waitForPageToLoad 10000
>>>>>>> >>        assertTrue("Failed to login",
>>>>>>> >> isElementPresent("welcomePage"))
>>>>>>> >>    }
>>>>>>> >>
>>>>>>> >> Now needs to be updated to;
>>>>>>> >>
>>>>>>> >>    public void login(String username, String password) {
>>>>>>> >>        type "login.username", username
>>>>>>> >>        type "login.password", password
>>>>>>> >>        click "login.submit"
>>>>>>> >>        waitForPageToLoad 10000
>>>>>>> >>        def result = waitForElementPresent("welcomePage", 5000)
>>>>>>> >>        assertTrue("Failed to login", result)
>>>>>>> >>    }
>>>>>>> >>
>>>>>>> >> I'm guessing this isn't the right solution, but it's home time for
>>>>>>> >> me
>>>>>>> >> now, I'll look into it further tomorrow.
>>>>>>> >>
>>>>>>> >>
>>>>>>> >> 2010/2/2 Jian Fang <[email protected]>:
>>>>>>> >> > List is fine. The remaining task for 0.7.0 is to refactor List
>>>>>>> >> > and Table
>>>>>>> >> > so
>>>>>>> >> > that you can reference them not by position only, but this
>>>>>>> >> > should be
>>>>>>> >> > after
>>>>>>> >> > the RC1 release.
>>>>>>> >> >
>>>>>>> >> > I will create another test case for you tonight.
>>>>>>> >> >
>>>>>>> >> > Thanks,
>>>>>>> >> >
>>>>>>> >> > Jian
>>>>>>> >> >
>>>>>>> >> > On Tue, Feb 2, 2010 at 10:26 AM, Jonathan Share
>>>>>>> >> > <[email protected]>
>>>>>>> >> > wrote:
>>>>>>> >> >>
>>>>>>> >> >> Thanks for the response, your solution looks nice, however my
>>>>>>> >> >> example
>>>>>>> >> >> html was perhaps a little oversimplified, the "option" div is
>>>>>>> >> >> repeated
>>>>>>> >> >> several times within the "segment clearfix" div and the whole
>>>>>>> >> >> "segment
>>>>>>> >> >> clearfix" div is also repeated several times, meaning there
>>>>>>> >> >> exists
>>>>>>> >> >> more than one list with class fares in the form (see more
>>>>>>> >> >> detailed
>>>>>>> >> >> outline below).
>>>>>>> >> >>
>>>>>>> >> >> Is there any better way to handle this situation? While
>>>>>>> >> >> creating the
>>>>>>> >> >> below outline I have just come up with an idea of trying to
>>>>>>> >> >> make a
>>>>>>> >> >> list out of the "segment clearfix" divs, instead of referencing
>>>>>>> >> >> them
>>>>>>> >> >> with xpath, disadvantage of this is that my uids will be
>>>>>>> >> >> slightly less
>>>>>>> >> >> expressive.
>>>>>>> >> >>
>>>>>>> >> >> Thanks for the help so far.
>>>>>>> >> >>
>>>>>>> >> >> Jonathan
>>>>>>> >> >>
>>>>>>> >> >> <form name="selectedSailingsForm">
>>>>>>> >> >>    <h1>Choose ship</h1>
>>>>>>> >> >>    <h3 class="inbound-outbound">Outbound</h3>
>>>>>>> >> >>    <h2 class="content-header"><!-- Route description --></h2>
>>>>>>> >> >>    <div class="segment clearfix">
>>>>>>> >> >>        <div class="option">
>>>>>>> >> >>            <ul class="fares">
>>>>>>> >> >>                <li>
>>>>>>> >> >>                    <input type="radio">&nbsp;
>>>>>>> >> >>                    <label>Economy</label>
>>>>>>> >> >>                </li>
>>>>>>> >> >>                <li>
>>>>>>> >> >>                    <input type="radio">&nbsp;
>>>>>>> >> >>                    <label>Flexible</label>
>>>>>>> >> >>                </li>
>>>>>>> >> >>            </ul>
>>>>>>> >> >>            <div class="details">
>>>>>>> >> >>                <dl>
>>>>>>> >> >>                    <dt>Ship:</dt>
>>>>>>> >> >>                    <dd><!-- Ship Name --></dd>
>>>>>>> >> >>                    <dt>Departs</dt>
>>>>>>> >> >>                    <dd>
>>>>>>> >> >>                        <em>08:00</em>
>>>>>>> >> >>                    </dd>
>>>>>>> >> >>                    <dt>Arrives</dt>
>>>>>>> >> >>                    <dd>
>>>>>>> >> >>                        <em>11:45</em>
>>>>>>> >> >>                    </dd>
>>>>>>> >> >>                </dl>
>>>>>>> >> >>            </div>
>>>>>>> >> >>        </div>
>>>>>>> >> >>        <div class="option">
>>>>>>> >> >>            <ul class="fares">
>>>>>>> >> >>                <li>
>>>>>>> >> >>                    <input type="radio">&nbsp;
>>>>>>> >> >>                    <label>Economy</label>
>>>>>>> >> >>                </li>
>>>>>>> >> >>                <li>
>>>>>>> >> >>                    <input type="radio">&nbsp;
>>>>>>> >> >>                    <label>Flexible</label>
>>>>>>> >> >>                </li>
>>>>>>> >> >>            </ul>
>>>>>>> >> >>            <div class="details">
>>>>>>> >> >>                <dl>
>>>>>>> >> >>                    <dt>Ship:</dt>
>>>>>>> >> >>                    <dd><!-- Ship Name --></dd>
>>>>>>> >> >>                    <dt>Departs</dt>
>>>>>>> >> >>                    <dd>
>>>>>>> >> >>                        <em>17:30</em>
>>>>>>> >> >>                    </dd>
>>>>>>> >> >>                    <dt>Arrives</dt>
>>>>>>> >> >>                    <dd>
>>>>>>> >> >>                        <em>21:15</em>
>>>>>>> >> >>                    </dd>
>>>>>>> >> >>                </dl>
>>>>>>> >> >>            </div>
>>>>>>> >> >>        </div>
>>>>>>> >> >>    </div>
>>>>>>> >> >>    <h3 class="inbound-outbound">Return</h3>
>>>>>>> >> >>
>>>>>>> >> >>    <h2 class="content-header"><!-- Route description --></h2>
>>>>>>> >> >>
>>>>>>> >> >>    <div class="segment clearfix">
>>>>>>> >> >>        <div class="option">
>>>>>>> >> >>            <ul class="fares">
>>>>>>> >> >>                <li>
>>>>>>> >> >>                    <input type="radio">&nbsp;
>>>>>>> >> >>                    <label>Economy</label>
>>>>>>> >> >>                </li>
>>>>>>> >> >>                <li>
>>>>>>> >> >>                    <input type="radio">&nbsp;
>>>>>>> >> >>                    <label>Flexible</label>
>>>>>>> >> >>                </li>
>>>>>>> >> >>            </ul>
>>>>>>> >> >>            <div class="details">
>>>>>>> >> >>                <div class="photo"><img></div>
>>>>>>> >> >>                <dl>
>>>>>>> >> >>                    <dt>Ship:</dt>
>>>>>>> >> >>                    <dd><!-- Ship Name --></dd>
>>>>>>> >> >>                    <dt>Departs</dt>
>>>>>>> >> >>                    <dd>
>>>>>>> >> >>                        <em>02:00</em>
>>>>>>> >> >>                    </dd>
>>>>>>> >> >>                    <dt>Arrives</dt>
>>>>>>> >> >>                    <dd>
>>>>>>> >> >>                        <em>06:00</em>
>>>>>>> >> >>                    </dd>
>>>>>>> >> >>                </dl>
>>>>>>> >> >>            </div>
>>>>>>> >> >>        </div>
>>>>>>> >> >>        <div class="option">
>>>>>>> >> >>            <ul class="fares">
>>>>>>> >> >>                <li>
>>>>>>> >> >>                    <input type="radio">&nbsp;
>>>>>>> >> >>                    <label>Economy</label>
>>>>>>> >> >>                </li>
>>>>>>> >> >>                <li>
>>>>>>> >> >>                    <input type="radio">&nbsp;
>>>>>>> >> >>                    <label>Flexible</label>
>>>>>>> >> >>                </li>
>>>>>>> >> >>            </ul>
>>>>>>> >> >>            <div class="details">
>>>>>>> >> >>                <dl>
>>>>>>> >> >>                    <dt>Ship:</dt>
>>>>>>> >> >>                    <dd><!-- Ship Name --></dd>
>>>>>>> >> >>                    <dt>Departs</dt>
>>>>>>> >> >>                    <dd>
>>>>>>> >> >>                        <em>12:45</em>
>>>>>>> >> >>                    </dd>
>>>>>>> >> >>                    <dt>Arrives</dt>
>>>>>>> >> >>                    <dd>
>>>>>>> >> >>                        <em>16:30</em>
>>>>>>> >> >>                    </dd>
>>>>>>> >> >>                </dl>
>>>>>>> >> >>            </div>
>>>>>>> >> >>        </div>
>>>>>>> >> >>    </div>
>>>>>>> >> >>    <div class="segment clearfix">
>>>>>>> >> >>        <!-- Other boring stuff -->
>>>>>>> >> >>    </div>
>>>>>>> >> >> </form>
>>>>>>> >> >>
>>>>>>> >> >> 2010/2/1 Jian Fang <[email protected]>:
>>>>>>> >> >> > Here is my test code
>>>>>>> >> >> >
>>>>>>> >> >> > UI Module
>>>>>>> >> >> >
>>>>>>> >> >> >
>>>>>>> >> >> >
>>>>>>> >> >> >
>>>>>>> >> >> > ----------------------------------------------------------------------------
>>>>>>> >> >> > package org.telluriumsource.module
>>>>>>> >> >> >
>>>>>>> >> >> > import org.telluriumsource.dsl.DslContext
>>>>>>> >> >> >
>>>>>>> >> >> > class JListModule extends DslContext {
>>>>>>> >> >> >
>>>>>>> >> >> >   public void defineUi(){
>>>>>>> >> >> >     ui.Form(uid: "selectedSailings", clocator: [name:
>>>>>>> >> >> > "selectedSailingsForm"]) {
>>>>>>> >> >> >       List(uid: "outgoingSailings", locator: "/div[1]") {
>>>>>>> >> >> >         Container(uid: "all", clocator: [tag: "div", 'class':
>>>>>>> >> >> > "option"])
>>>>>>> >> >> > {
>>>>>>> >> >> >           List(uid: "fares", clocator: [tag: "ul"]) {
>>>>>>> >> >> >             Container(uid: "all", clocator: [tag: "li"]) {
>>>>>>> >> >> >               RadioButton(uid: "radio", clocator: [:],
>>>>>>> >> >> > respond:
>>>>>>> >> >> > ["click"])
>>>>>>> >> >> >               TextBox(uid: "label", clocator: [tag: "label"])
>>>>>>> >> >> >             }
>>>>>>> >> >> >           }
>>>>>>> >> >> >           TextBox(uid: "departureTime", locator:
>>>>>>> >> >> > "/div/dl/dd/em[1]")
>>>>>>> >> >> >         }
>>>>>>> >> >> >       }
>>>>>>> >> >> >     }
>>>>>>> >> >> >
>>>>>>> >> >> >     ui.Form(uid: "Sailings", clocator: [name:
>>>>>>> >> >> > "selectedSailingsForm"]){
>>>>>>> >> >> >       List(uid: "Fares", clocator: [tag: "ul", class:
>>>>>>> >> >> > "fares"],
>>>>>>> >> >> > separator:
>>>>>>> >> >> > "li"){
>>>>>>> >> >> >         Container(uid: "all"){
>>>>>>> >> >> >             RadioButton(uid: "radio", clocator: [:], respond:
>>>>>>> >> >> > ["click"])
>>>>>>> >> >> >             TextBox(uid: "label", clocator: [tag: "label"])
>>>>>>> >> >> >         }
>>>>>>> >> >> >       }
>>>>>>> >> >> >     }
>>>>>>> >> >> >   }
>>>>>>> >> >> > }
>>>>>>> >> >> >
>>>>>>> >> >> >
>>>>>>> >> >> >
>>>>>>> >> >> > --------------------------------------------------------------------------------------------------
>>>>>>> >> >> >
>>>>>>> >> >> > Test Case
>>>>>>> >> >> >
>>>>>>> >> >> >
>>>>>>> >> >> >
>>>>>>> >> >> >
>>>>>>> >> >> > -------------------------------------------------------------------------------------------------
>>>>>>> >> >> > package org.telluriumsource.ft;
>>>>>>> >> >> >
>>>>>>> >> >> > import org.junit.AfterClass;
>>>>>>> >> >> > import org.junit.Before;
>>>>>>> >> >> > import org.junit.BeforeClass;
>>>>>>> >> >> > import org.junit.Test;
>>>>>>> >> >> > import org.telluriumsource.module.JListModule;
>>>>>>> >> >> > import
>>>>>>> >> >> > org.telluriumsource.test.java.TelluriumMockJUnitTestCase;
>>>>>>> >> >> >
>>>>>>> >> >> > public class JListTestJUnitCase extends
>>>>>>> >> >> > TelluriumMockJUnitTestCase {
>>>>>>> >> >> >    private static JListModule jlm;
>>>>>>> >> >> >
>>>>>>> >> >> >     @BeforeClass
>>>>>>> >> >> >     public static void initUi() {
>>>>>>> >> >> >         registerHtmlBody("JList");
>>>>>>> >> >> >
>>>>>>> >> >> >         jlm = new JListModule();
>>>>>>> >> >> >         jlm.defineUi();
>>>>>>> >> >> > //        useCssSelector(true);
>>>>>>> >> >> > //        useTelluriumApi(true);
>>>>>>> >> >> >         useTrace(true);
>>>>>>> >> >> > //        useCache(true);
>>>>>>> >> >> > //        useMacroCmd(true);
>>>>>>> >> >> >         useEngineLog(true);
>>>>>>> >> >> >     }
>>>>>>> >> >> >
>>>>>>> >> >> >     @Before
>>>>>>> >> >> >     public void connectToLocal() {
>>>>>>> >> >> >         connect("JList");
>>>>>>> >> >> >     }
>>>>>>> >> >> >
>>>>>>> >> >> >     @Test   //This works fine if the following two commands
>>>>>>> >> >> > are used:
>>>>>>> >> >> > useCache(true); useTelluriumApi(true);
>>>>>>> >> >> >     public void testGetListSize(){
>>>>>>> >> >> >         int size =
>>>>>>> >> >> >
>>>>>>> >> >> > jlm.getListSize("selectedSailings.outgoingSailings[1].fares");
>>>>>>> >> >> >         System.out.println("List Size " + size);
>>>>>>> >> >> >     }
>>>>>>> >> >> >
>>>>>>> >> >> >     @Test
>>>>>>> >> >> >     public void testGetNewListSize(){
>>>>>>> >> >> >         int size = jlm.getListSize("Sailings.Fares");
>>>>>>> >> >> >         System.out.println("List Size " + size);
>>>>>>> >> >> >
>>>>>>> >> >> >     }
>>>>>>> >> >> >
>>>>>>> >> >> >     @AfterClass
>>>>>>> >> >> >     public static void tearDown(){
>>>>>>> >> >> >         showTrace();
>>>>>>> >> >> >     }
>>>>>>> >> >> > }
>>>>>>> >> >> >
>>>>>>> >> >> >
>>>>>>> >> >> >
>>>>>>> >> >> > On Mon, Feb 1, 2010 at 11:05 AM, Jian Fang
>>>>>>> >> >> > <[email protected]>
>>>>>>> >> >> > wrote:
>>>>>>> >> >> >>
>>>>>>> >> >> >> Hi,
>>>>>>> >> >> >>
>>>>>>> >> >> >> Your UI module definition might be problematic. I used the
>>>>>>> >> >> >> following
>>>>>>> >> >> >> one
>>>>>>> >> >> >> and can get back the list size 2 correctly
>>>>>>> >> >> >>
>>>>>>> >> >> >>     ui.Form(uid: "Sailings", clocator: [name:
>>>>>>> >> >> >> "selectedSailingsForm"]){
>>>>>>> >> >> >>       List(uid: "Fares", clocator: [tag: "ul", class:
>>>>>>> >> >> >> "fares"],
>>>>>>> >> >> >> separator:
>>>>>>> >> >> >> "li"){
>>>>>>> >> >> >>         Container(uid: "all"){
>>>>>>> >> >> >>             RadioButton(uid: "radio", clocator: [:],
>>>>>>> >> >> >> respond:
>>>>>>> >> >> >> ["click"])
>>>>>>> >> >> >>             TextBox(uid: "label", clocator: [tag: "label"])
>>>>>>> >> >> >>         }
>>>>>>> >> >> >>       }
>>>>>>> >> >> >>     }
>>>>>>> >> >> >>
>>>>>>> >> >> >> You should use the logical container to include the list
>>>>>>> >> >> >> elements.
>>>>>>> >> >> >>
>>>>>>> >> >> >> Also, please don't use hard coded xpath there, otherwise,
>>>>>>> >> >> >> your test
>>>>>>> >> >> >> is
>>>>>>> >> >> >> not
>>>>>>> >> >> >> robust to changes. Also, most 0.7.0 new
>>>>>>> >> >> >> features require the clocator.
>>>>>>> >> >> >>
>>>>>>> >> >> >> Interesting thing is I can get back the correct List size
>>>>>>> >> >> >> even with
>>>>>>> >> >> >> your
>>>>>>> >> >> >> UI module with new Tellurium API. I will
>>>>>>> >> >> >> post all my test code soon.
>>>>>>> >> >> >>
>>>>>>> >> >> >> Thanks,
>>>>>>> >> >> >>
>>>>>>> >> >> >> Jian
>>>>>>> >> >> >>
>>>>>>> >> >> >> On Mon, Feb 1, 2010 at 10:49 AM, Jian Fang
>>>>>>> >> >> >> <[email protected]>
>>>>>>> >> >> >> wrote:
>>>>>>> >> >> >>>
>>>>>>> >> >> >>> You are right, the new core added a WorkflowContext
>>>>>>> >> >> >>> variable to all
>>>>>>> >> >> >>> Accessor methods
>>>>>>> >> >> >>> so that we can pass in meta data to the tiers under it.
>>>>>>> >> >> >>> That is why
>>>>>>> >> >> >>> it
>>>>>>> >> >> >>> cannot find the method with
>>>>>>> >> >> >>> the old snapshot.
>>>>>>> >> >> >>>
>>>>>>> >> >> >>> Thanks,
>>>>>>> >> >> >>>
>>>>>>> >> >> >>> Jian
>>>>>>> >> >> >>>
>>>>>>> >> >> >>> On Mon, Feb 1, 2010 at 10:35 AM, Jonathan Share
>>>>>>> >> >> >>> <[email protected]>
>>>>>>> >> >> >>> wrote:
>>>>>>> >> >> >>>>
>>>>>>> >> >> >>>> Thanks, I'm also having problems with getXpathCount, but
>>>>>>> >> >> >>>> that may
>>>>>>> >> >> >>>> be
>>>>>>> >> >> >>>> because I'm using an old snapshot in order to work around
>>>>>>> >> >> >>>> the list
>>>>>>> >> >> >>>> problem.
>>>>>>> >> >> >>>>
>>>>>>> >> >> >>>> "groovy.lang.MissingMethodException: No signature of
>>>>>>> >> >> >>>> method:
>>>>>>> >> >> >>>> org.telluriumsource.access.Accessor.getXpathCount() is
>>>>>>> >> >> >>>> applicable
>>>>>>> >> >> >>>> for
>>>>>>> >> >> >>>> argument types: (java.lang.String) values:
>>>>>>> >> >> >>>>
>>>>>>> >> >> >>>>
>>>>>>> >> >> >>>>
>>>>>>> >> >> >>>>
>>>>>>> >> >> >>>> [//descendant-or-self::tab...@id="supplierEditor"]/tbody/tr[child::td]/td[1]]"
>>>>>>> >> >> >>>>
>>>>>>> >> >> >>>> 2010/2/1 Jian Fang <[email protected]>:
>>>>>>> >> >> >>>> > Thanks for reporting the problem. I will create a test
>>>>>>> >> >> >>>> > case and
>>>>>>> >> >> >>>> > see
>>>>>>> >> >> >>>> > what
>>>>>>> >> >> >>>> > happens.
>>>>>>> >> >> >>>> >
>>>>>>> >> >> >>>> > Thanks,
>>>>>>> >> >> >>>> >
>>>>>>> >> >> >>>> > Jian
>>>>>>> >> >> >>>> >
>>>>>>> >> >> >>>> > On Mon, Feb 1, 2010 at 7:20 AM, Jonathan Share
>>>>>>> >> >> >>>> > <[email protected]>
>>>>>>> >> >> >>>> > wrote:
>>>>>>> >> >> >>>> >>
>>>>>>> >> >> >>>> >> Hi,
>>>>>>> >> >> >>>> >>
>>>>>>> >> >> >>>> >> I seem to be having a little problem with getListSize.
>>>>>>> >> >> >>>> >> When I
>>>>>>> >> >> >>>> >> call
>>>>>>> >> >> >>>> >> that method tellurium crashes on me with the following
>>>>>>> >> >> >>>> >> exception;
>>>>>>> >> >> >>>> >>
>>>>>>> >> >> >>>> >> com.thoughtworks.selenium.SeleniumException: ERROR:
>>>>>>> >> >> >>>> >> Element
>>>>>>> >> >> >>>> >>
>>>>>>> >> >> >>>> >>
>>>>>>> >> >> >>>> >>
>>>>>>> >> >> >>>> >>
>>>>>>> >> >> >>>> >>
>>>>>>> >> >> >>>> >> //descendant-or-self::fo...@name="selectedSailingsForm"]/div[1]/d...@class="option"][1]/descendant-or-self::ul/li[3]
>>>>>>> >> >> >>>> >> not found
>>>>>>> >> >> >>>> >>
>>>>>>> >> >> >>>> >> The interesting thing to note here is that there are
>>>>>>> >> >> >>>> >> only two
>>>>>>> >> >> >>>> >> li
>>>>>>> >> >> >>>> >> elements in the list. Is this a bug that has crept into
>>>>>>> >> >> >>>> >> tellurium
>>>>>>> >> >> >>>> >> or
>>>>>>> >> >> >>>> >> am I doing something really stupid in my test?
>>>>>>> >> >> >>>> >>
>>>>>>> >> >> >>>> >> Thanks in advance
>>>>>>> >> >> >>>> >>
>>>>>>> >> >> >>>> >> Jonathan
>>>>>>> >> >> >>>> >>
>>>>>>> >> >> >>>> >> // MODEL
>>>>>>> >> >> >>>> >> ui.Form(uid: "selectedSailings", clocator: [name:
>>>>>>> >> >> >>>> >> "selectedSailingsForm"])
>>>>>>> >> >> >>>> >> {
>>>>>>> >> >> >>>> >>            List(uid: "outgoingSailings", locator:
>>>>>>> >> >> >>>> >> "/div[1]") {
>>>>>>> >> >> >>>> >>                Container(uid: "all", clocator: [tag:
>>>>>>> >> >> >>>> >> "div",
>>>>>>> >> >> >>>> >> 'class':
>>>>>>> >> >> >>>> >> "option"]) {
>>>>>>> >> >> >>>> >>                    List(uid: "fares", clocator: [tag:
>>>>>>> >> >> >>>> >> "ul"]) {
>>>>>>> >> >> >>>> >>                        Container(uid: "all", clocator:
>>>>>>> >> >> >>>> >> [tag:
>>>>>>> >> >> >>>> >> "li"]) {
>>>>>>> >> >> >>>> >>                            RadioButton(uid: "radio",
>>>>>>> >> >> >>>> >> clocator:
>>>>>>> >> >> >>>> >> [:],
>>>>>>> >> >> >>>> >> respond: ["click"])
>>>>>>> >> >> >>>> >>                            TextBox(uid: "label",
>>>>>>> >> >> >>>> >> clocator:
>>>>>>> >> >> >>>> >> [tag:
>>>>>>> >> >> >>>> >> "label"])
>>>>>>> >> >> >>>> >>                        }
>>>>>>> >> >> >>>> >>                    }
>>>>>>> >> >> >>>> >>                    TextBox(uid: "departureTime",
>>>>>>> >> >> >>>> >> locator:
>>>>>>> >> >> >>>> >> "/div/dl/dd/em[1]")
>>>>>>> >> >> >>>> >>                }
>>>>>>> >> >> >>>> >>            }
>>>>>>> >> >> >>>> >> }
>>>>>>> >> >> >>>> >>
>>>>>>> >> >> >>>> >> // TEST LINE THAT FAILS
>>>>>>> >> >> >>>> >> def numPricesForSailing =
>>>>>>> >> >> >>>> >>
>>>>>>> >> >> >>>> >> getListSize("selectedSailings.outgoingSailings[1].fares")
>>>>>>> >> >> >>>> >>
>>>>>>> >> >> >>>> >> // HTML (edited a little)
>>>>>>> >> >> >>>> >> <form action="..." id="airDetailsForm" method="POST"
>>>>>>> >> >> >>>> >> name="selectedSailingsForm">
>>>>>>> >> >> >>>> >>  <div class="segment clearfix">
>>>>>>> >> >> >>>> >>    <div class="option">
>>>>>>> >> >> >>>> >>      <ul class="fares">
>>>>>>> >> >> >>>> >>        <li>
>>>>>>> >> >> >>>> >>          <input id="..." name="..." type="radio"
>>>>>>> >> >> >>>> >> value="..."
>>>>>>> >> >> >>>> >> checked
>>>>>>> >> >> >>>> >> onclick="enableDisable(1,2)">&nbsp;<label
>>>>>>> >> >> >>>> >> for="..."><strong><span
>>>>>>> >> >> >>>> >> id="...">3,000</span>KR</strong>economy</label>
>>>>>>> >> >> >>>> >>        </li>
>>>>>>> >> >> >>>> >>        <li>
>>>>>>> >> >> >>>> >>          <input id="..." name="..." type="radio"
>>>>>>> >> >> >>>> >> value="..."
>>>>>>> >> >> >>>> >> onclick="enableDisable(1,1)">&nbsp;<label
>>>>>>> >> >> >>>> >> for="..."><strong><span
>>>>>>> >> >> >>>> >> id="...">4,000</span>KR</strong>&nbsp;Flexible</label>
>>>>>>> >> >> >>>> >>        </li>
>>>>>>> >> >> >>>> >>      </ul>
>>>>>>> >> >> >>>> >>    </div>
>>>>>>> >> >> >>>> >>  </div>
>>>>>>> >> >> >>>> >> </form>
>>>>>>> >> >> >>>> >>
>>>>>>> >> >> >>>> >> --
>>>>>>> >> >> >>>> >> You received this message because you are subscribed to
>>>>>>> >> >> >>>> >> the
>>>>>>> >> >> >>>> >> Google
>>>>>>> >> >> >>>> >> Groups
>>>>>>> >> >> >>>> >> "tellurium-users" group.
>>>>>>> >> >> >>>> >> To post to this group, send email to
>>>>>>> >> >> >>>> >> [email protected].
>>>>>>> >> >> >>>> >> To unsubscribe from this group, send email to
>>>>>>> >> >> >>>> >> [email protected].
>>>>>>> >> >> >>>> >> For more options, visit this group at
>>>>>>> >> >> >>>> >> http://groups.google.com/group/tellurium-users?hl=en.
>>>>>>> >> >> >>>> >>
>>>>>>> >> >> >>>> >
>>>>>>> >> >> >>>> > --
>>>>>>> >> >> >>>> > You received this message because you are subscribed to
>>>>>>> >> >> >>>> > the
>>>>>>> >> >> >>>> > Google
>>>>>>> >> >> >>>> > Groups
>>>>>>> >> >> >>>> > "tellurium-users" group.
>>>>>>> >> >> >>>> > To post to this group, send email to
>>>>>>> >> >> >>>> > [email protected].
>>>>>>> >> >> >>>> > To unsubscribe from this group, send email to
>>>>>>> >> >> >>>> > [email protected].
>>>>>>> >> >> >>>> > For more options, visit this group at
>>>>>>> >> >> >>>> > http://groups.google.com/group/tellurium-users?hl=en.
>>>>>>> >> >> >>>> >
>>>>>>> >> >> >>>>
>>>>>>> >> >> >>>> --
>>>>>>> >> >> >>>> You received this message because you are subscribed to
>>>>>>> >> >> >>>> the Google
>>>>>>> >> >> >>>> Groups "tellurium-users" group.
>>>>>>> >> >> >>>> To post to this group, send email to
>>>>>>> >> >> >>>> [email protected].
>>>>>>> >> >> >>>> To unsubscribe from this group, send email to
>>>>>>> >> >> >>>> [email protected].
>>>>>>> >> >> >>>> For more options, visit this group at
>>>>>>> >> >> >>>> http://groups.google.com/group/tellurium-users?hl=en.
>>>>>>> >> >> >>>>
>>>>>>> >> >> >>>
>>>>>>> >> >> >>
>>>>>>> >> >> >
>>>>>>> >> >> > --
>>>>>>> >> >> > You received this message because you are subscribed to the
>>>>>>> >> >> > Google
>>>>>>> >> >> > Groups
>>>>>>> >> >> > "tellurium-users" group.
>>>>>>> >> >> > To post to this group, send email to
>>>>>>> >> >> > [email protected].
>>>>>>> >> >> > To unsubscribe from this group, send email to
>>>>>>> >> >> > [email protected].
>>>>>>> >> >> > For more options, visit this group at
>>>>>>> >> >> > http://groups.google.com/group/tellurium-users?hl=en.
>>>>>>> >> >> >
>>>>>>> >> >>
>>>>>>> >> >> --
>>>>>>> >> >> You received this message because you are subscribed to the
>>>>>>> >> >> Google
>>>>>>> >> >> Groups
>>>>>>> >> >> "tellurium-users" group.
>>>>>>> >> >> To post to this group, send email to
>>>>>>> >> >> [email protected].
>>>>>>> >> >> To unsubscribe from this group, send email to
>>>>>>> >> >> [email protected].
>>>>>>> >> >> For more options, visit this group at
>>>>>>> >> >> http://groups.google.com/group/tellurium-users?hl=en.
>>>>>>> >> >>
>>>>>>> >> >
>>>>>>> >> > --
>>>>>>> >> > You received this message because you are subscribed to the
>>>>>>> >> > Google
>>>>>>> >> > Groups
>>>>>>> >> > "tellurium-users" group.
>>>>>>> >> > To post to this group, send email to
>>>>>>> >> > [email protected].
>>>>>>> >> > To unsubscribe from this group, send email to
>>>>>>> >> > [email protected].
>>>>>>> >> > For more options, visit this group at
>>>>>>> >> > http://groups.google.com/group/tellurium-users?hl=en.
>>>>>>> >> >
>>>>>>> >>
>>>>>>> >> --
>>>>>>> >> You received this message because you are subscribed to the Google
>>>>>>> >> Groups
>>>>>>> >> "tellurium-users" group.
>>>>>>> >> To post to this group, send email to
>>>>>>> >> [email protected].
>>>>>>> >> To unsubscribe from this group, send email to
>>>>>>> >> [email protected].
>>>>>>> >> For more options, visit this group at
>>>>>>> >> http://groups.google.com/group/tellurium-users?hl=en.
>>>>>>> >>
>>>>>>> >
>>>>>>> > --
>>>>>>> > You received this message because you are subscribed to the Google
>>>>>>> > Groups
>>>>>>> > "tellurium-users" group.
>>>>>>> > To post to this group, send email to
>>>>>>> > [email protected].
>>>>>>> > To unsubscribe from this group, send email to
>>>>>>> > [email protected].
>>>>>>> > For more options, visit this group at
>>>>>>> > http://groups.google.com/group/tellurium-users?hl=en.
>>>>>>> >
>>>>>>>
>>>>>>> --
>>>>>>> You received this message because you are subscribed to the Google
>>>>>>> Groups "tellurium-users" group.
>>>>>>> To post to this group, send email to
>>>>>>> [email protected].
>>>>>>> To unsubscribe from this group, send email to
>>>>>>> [email protected].
>>>>>>> For more options, visit this group at
>>>>>>> http://groups.google.com/group/tellurium-users?hl=en.
>>>>>>>
>>>>>>
>>>>>
>>>>
>>>
>>
>
> --
> You received this message because you are subscribed to the Google Groups
> "tellurium-users" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected].
> For more options, visit this group at
> http://groups.google.com/group/tellurium-users?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"tellurium-users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/tellurium-users?hl=en.

Reply via email to