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

Is there any place like TestInitialize for me to add some customize steps for setting up environment?

5 Answers 46 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Tom
Top achievements
Rank 1
Tom asked on 15 Feb 2011, 10:27 AM
Hi,

Is any one know if there had some place in WebUI Test Project Solution where i could changed for adding customize steps for setting up environment just like TestInitialize method in VS Test project?


Regards,
Tom

5 Answers, 1 is accepted

Sort by
0
Stoich
Telerik team
answered on 15 Feb 2011, 10:50 AM
Hello Tom,
    yes, there is. Please check out this KB article:
http://www.telerik.com/automated-testing-tools/support/kb/code/executing-custom-scripts-before-after-your-test-runs.aspx

Let me know if you have any problems with getting this to work!

Best wishes,
Stoich
the Telerik team
Interested in Agile Testing? Check out Telerik TV for a recording of Automated Testing in the Agile Environment
0
Tom
Top achievements
Rank 1
answered on 15 Feb 2011, 10:58 AM
Thanks for your information!,
And i had another question - if there had some place could i keep some global variables which could be used in several customized test cases?

Regards,
Tom
0
Stoich
Telerik team
answered on 15 Feb 2011, 04:41 PM
Hi Tom,
   would you please clarify what you mean by "test cases"? Are you referring to Coded Steps?

If so, you can declare and use global variables in the "code behind" class where all the coded steps are stored.
Just make sure you declare them inside the class but outside each individual method (coded steps are represented as methods). From here all methods (i.e. coded steps) in your test can access it. See screenshot 1.

Best wishes,
Stoich
the Telerik team
Interested in Agile Testing? Check out Telerik TV for a recording of Automated Testing in the Agile Environment
0
Tom
Top achievements
Rank 1
answered on 17 Feb 2011, 03:32 AM
Is this feature could be used in Developer Edition of WebUI Test Studio?
0
Stoich
Telerik team
answered on 21 Feb 2011, 01:08 PM
Hello Tom,
    yes, just turn a step to code. Once you do that you'll be able to see the entire code-behind class. You can implement this solution there.

Let me know how it goes!

Regards,
Stoich
the Telerik team
Registration for Q1 2011 What’s New Webinar Week is now open. Mark your calendar for the week starting March 21st and book your seat for a walk through all the exciting stuff we ship with the new release!
Tags
General Discussions
Asked by
Tom
Top achievements
Rank 1
Answers by
Stoich
Telerik team
Tom
Top achievements
Rank 1
Share this question
or