Support for IFrames??

4 views
Skip to first unread message

Haroon Rasheed

unread,
Oct 27, 2008, 5:35:14 PM10/27/08
to telluri...@googlegroups.com

Do we have support for IFrames in Tellurium?? Is there any way to instruct Tellurium to interact with the UI within the IFrames??? Also how can I define the UI for elements defined within an IFrame?

 

 

 

Thanks

Haroon

John.Ji...@gmail.com

unread,
Oct 27, 2008, 8:46:57 PM10/27/08
to tellurium-users
Great question and also a tough one.

Right now, Tellurium does not handle anything special for IFrame and
just passes the
calls directly to Selenium core. Selenium provides the following
methods for Frame/IFrame,

void selectFrame(String locator);
boolean getWhetherThisFrameMatchFrameExpression(String
currentFrameString,String target);
void waitForFrameToLoad(String frameAddress,String timeout);

I doubt what Tellurium can provide for IFrame other than the above
methods without modifying
Selenium Core. The most important thing is what are the additional
features we like Tellurium
to provide other than the ones that have already been provided by
Selenium. If there is huge benefit there,
yes, sure, we will need to hack into Selenium core and add these
features. What's in your mind?

Thanks,

Jian

John.Ji...@gmail.com

unread,
Oct 28, 2008, 10:44:45 PM10/28/08
to tellurium-users
Hi all,

We added the Frame object for Frame or IFrame UI elements. The Frame
object is a container type
and the following DSLs can be applied to the Frame object,

selectFrame UID
selectParentFrameFrom UID
selectTopFrameFrom UID
getWhetherThisFrameMatchFrameExpression UID, target
waitForFrameToLoad timeout

One example UI module is as follows,

ui.Frame(uid: "SubscribeFrame", name: "subscrbe"){
Form(uid: "LoginForm", clocator: [name: "loginForm"]){
InputBox(uid: "UserName", clocator: [id: "username", type:
"text"])
InputBox(uid: "Password", clocator: [id: "password", type:
"password"])
Button(uid: "Login", clocator: [type: "image", class: "login"])
CheckBox(uid: "RememberMe", clocator: [id: "rememberme"])
}
}

The actual script looks as follows,

selectFrame "SubscribeFrame"
uncheck "SubscribeFrame.LoginForm.RememberMe"
keyType "SubscribeFrame.LoginForm.UserName", username
keyType "SubscribeFrame.LoginForm.Password", password
click "SubscribeFrame.LoginForm.Login"
selectTopFrameFrom "SubscribeFrame"
waitForPageToLoad 30000

Also be aware that you should use multiple windows to test IFrame,
i.e., set the useMultiWindows attribute to be true in the
TelluriumConfig.groovy file as follows,

tellurium{
embeddedserver {
......
useMultiWindows = true
......
}
}
Reply all
Reply to author
Forward
0 new messages