This is a migrated thread and some comments may be shown as answers.

Descriptive Programming on Telerik

5 Answers 66 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Dalsingh
Top achievements
Rank 1
Dalsingh asked on 31 Aug 2010, 12:36 PM

How can we write a Descriptive Programming on Telerik.
There are cases I don't want to capture the Elements into the repository and access them into the scripts. So I would like to try with Desc Programming, Can anybody guide us how that can be achieved in Telerik.

Regards,
Dalsingh

5 Answers, 1 is accepted

Sort by
0
Daniel Levy
Telerik team
answered on 02 Sep 2010, 05:58 PM
Hi Dalsingh,

I am including a link to documentation on how to write your own HTML and XAML find expressions in WebUI Test Studio. You will also want to look through our documentation on finding page elements, which I suspect will be helpful as well.

If you have any additional questions, please do not hesitate to reach out.

All the best,
Daniel Levy
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Ajay
Top achievements
Rank 1
answered on 15 Jun 2011, 08:42 AM

Hi Daniel Levy

What are leminations of Descriptive Programming in Telerik web ui test studio?

Can you explain Descriptive Programming step by step.

I am purely tester not developer precisely using QTP in vb scripting. Please give Eg: for login page in Descriptive Programming in Telerik web ui test studio.

QTP Descriptive Programming

 Set g=Browser("name:=Yahoo.*").Page("title:=Yahoo.*")
g.WebEdit("name:=login").Set "aaa"
g.WebEdit("name:=passwd").SetSecure "bbb"
g.WebButton("name:=Sign In").Click
g.Link("name:=Inbox.*",
"html id:=WelcomeInboxFolderLink").Click
g.Link("name:=Sign Out").Click

 QTP recorder

Browser("micclass:=Browser").page("micclass:=Page).webedit("name:=txtusername).set

xxxxxx

Browser("micclass:=Browser").page("micclass:=Page).webedit("name:=password).setsecure

xxxxxx

Browser("micclass:=Browser").page("micclass:=Page).webutton("name:=Button).click

 

 Then to explain telerik

Hi Daniel Levy

What are leminations of Descriptive Programming in Telerik web ui test studio?

Can you explain Descriptive Programming step by step.

I am purely tester not developer precisely using QTP in vb scripting. Please give Eg: for login page in Descriptive Programming in Telerik web ui test studio.

QTP Descriptive Programming

 Set g=Browser("name:=Yahoo.*").Page("title:=Yahoo.*")
g.WebEdit("name:=login").Set "aaa"
g.WebEdit("name:=passwd").SetSecure "bbb"
g.WebButton("name:=Sign In").Click
g.Link("name:=Inbox.*",
"html id:=WelcomeInboxFolderLink").Click
g.Link("name:=Sign Out").Click

 QTP recorder

Browser("micclass:=Browser").page("micclass:=Page).webedit("name:=txtusername).set

xxxxxx

Browser("micclass:=Browser").page("micclass:=Page).webedit("name:=password).setsecure

xxxxxx

Browser("micclass:=Browser").page("micclass:=Page).webutton("name:=Button).click

 

 

Then to explain to telerik Descriptive Programming

to go script as step to select

c# or visual basic known that to explain in depth  Descriptive Programming process

0
Stoich
Telerik team
answered on 21 Jun 2011, 01:41 PM
Hi Ranjith,
    I'm not familiar with Descriptive Programming in QTP. My guess is that Test Studio's Coded Steps is what you're looking for. Check out our online documentation on this:
http://www.telerik.com/automated-testing-tools/support/documentation/user-guide/coded_steps.aspx

All the best,
Stoich
the Telerik team
Do you think you know all the new features coming out in Test Studio R1 2011? Think again - we have some surprises and will share them with you in the What's New in Test Studio R1 2011 Webinar on May 12th.
Register Today!
0
Austin
Top achievements
Rank 1
answered on 24 Oct 2018, 01:28 PM

I need all commands i.e. descriptive programming for coded steps in test Studio.

Some I have figured out on my own, remaining i need.

e.g

i. To Find click and type in text box.

Element attendee_type =  Find.ByXPath("//input[@id='AttendeeType1']"); 
ActiveBrowser.Actions.Click(attendee_type);  
ActiveBrowser.Actions.SetText(attendee_type,"test1"); 

ii. To put static wait

System.Threading.Thread.Sleep(10000);

 

ii. Handle drop down

Pages.AustunPage.Dashboard_SystemClient_DropDown.SelectByText("mileage_system_client", true);

 

iii. To wait and verify element present

Pages.AustinPage.ProjectDetail_MileageRates_HeaderPane0.Wait.ForExists(30000);
 Assert.AreEqual(true, Pages.MeetingSourceExpense2.ProjectDetail_MileageRates_HeaderPane0.IsVisible());

 

I want simple C# + Test Studio commands to write my coded steps.

1. Put dynamic/explicit/fluent wait on identified element

.2. Handle drop down(something like SELECT Class in selenium)- Not by recording.

3. get attribute value of identified element

4. get text of identified element

 

 

 

 

 

 

0
Elena
Telerik team
answered on 06 Nov 2018, 12:55 PM
Hello Austin,

Thank you for contacting us. 

Please note you are referring a forum post from over 7 years ago and as such the information in i, might not be relevant anymore. As a licensed user of Test Studio you can also submit your queries in support tickets to get assistance in a timely manner. 

In regards the queries you have, I guess you will find very useful our exposed APIs documentation. In addition to that we have some samples prepared in our documentation for the listed topics. Please find details about your queries below: 
1. HtmlWait class 
2. Handling a drop down depends on the exact implementation. Basically you need to toggle the drop down to show the list of items to select. If the control is dynamic, the list will appear in the DOM tree and you need to locate and identify it and select the desired list element. When doing this in code only, you will need to refresh the DOM tree between the toggle and the selection of item. 
3. and 4 should be covered by the Html Assert class

I hope these will be useful for you. Though in case you need any further assistance, please do not hesitate to contact us again. Thanks. 

Regards,
Elena Tsvetkova
Progress Telerik
 
Quickly become an expert in Test Studio, check out our new training sessions!
Test Studio Trainings
 
Tags
General Discussions
Asked by
Dalsingh
Top achievements
Rank 1
Answers by
Daniel Levy
Telerik team
Ajay
Top achievements
Rank 1
Stoich
Telerik team
Austin
Top achievements
Rank 1
Elena
Telerik team
Share this question
or