Hi,
I created a test case for your html and seems it works fine for both
Selenium Core and Tellurium Engine.
class DisplayModule extends DslContext {
public void defineUi() {
ui.Container(uid: "Container1", clocator: [tag: "div", id:
"Container1"])
}
}
public class DisplayTestCase extends TelluriumMockJUnitTestCase {
private static DisplayModule dm;
@BeforeClass
public static void initUi() {
registerHtml("Display");
dm = new DisplayModule();
dm.defineUi();
}
@Before
public void connectToLocal() {
connect("Display");
}
@Test
public void testIsVisibleForSelenium(){
useTelluriumEngine(true);
assertFalse(dm.isVisible("Container1"));
}
@Test
public void testIsVisibleForTellurium(){
useTelluriumEngine(false);
assertFalse(dm.isVisible("Container1"));
}
}
The test code is available from trunk/core at
http://code.google.com/p/aost/source/browse/trunk/core/src/test/groovy/org/telluriumsource/ft/DisplayTestCase.java
Thanks,
Jian
On Mon, Jul 12, 2010 at 3:49 PM, Jian Fang <[email protected]> wrote:
> Are you using Selenium core (the default one) or the Tellurium new Engine?
>
> I will create a test case for this.
>
> Thanks,
>
> Jian
>
>
> On Mon, Jul 12, 2010 at 3:42 PM, super fan 911 <[email protected]>wrote:
>
>> Our developers are using style sheet to show/hide elements. But,
>> isVisible is always returning true.
>>
>> <div id="Container1" style="display: none;" />
>>
>> isVisible("Container1");
>>
>> I am using getAttribute to check the style sheet as a workaround for
>> now.
>>
>> return !getAttribute ("Container1",
>> "style").equalsIgnoreCase("display: none;");
>>
>> Is my usage of isVisible method correct?
>>
>>
>> --
>> 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]<tellurium-users%[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.