Ask a Question

How can I initialize parameters for my keyword test before running the Keyword test.

SOLVED
vsumathi
Occasional Contributor

How can I initialize parameters for my keyword test before running the Keyword test.

I have a login page that has three fields ('username', 'password','company' ). 'Company' can have two values ( X or Y). 

For the company field, I created a parameter and want to assign the value X or Y

My requirement is to schedule a job to run my automatic test and have the ability to specify which values I should set for the company filed ( 'X' or 'Y' ) 

1 ACCEPTED SOLUTION

Accepted Solutions
Marsha_R
Community Hero

Re: How can I initialize parameters for my keyword test before running the Keyword test.

You can

1) Use an input box to enter the value every time you run the test

 https://support.smartbear.com/testcomplete/docs/reference/program-objects/builtin/inputbox.html

2) Use a variable for the value and edit the variable before you run the test

3) Generate a random number and have your test run one way or the other depending on the random number

https://support.smartbear.com/viewarticle/54645/

4) Have your test read the value from a spreadsheet or a text file and edit the value before you run the test.

https://support.smartbear.com/testcomplete/docs/reference/program-objects/ddt/index.html


Marsha_R
[Community Hero]
____
[Community Heroes] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Heroes]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Hero] signature is used with permission by SmartBear Software.
https://community.smartbear.com/t5/custom/page/page-id/hall-of-fame

View solution in original post

2 REPLIES 2
Marsha_R
Community Hero

Re: How can I initialize parameters for my keyword test before running the Keyword test.

You can

1) Use an input box to enter the value every time you run the test

 https://support.smartbear.com/testcomplete/docs/reference/program-objects/builtin/inputbox.html

2) Use a variable for the value and edit the variable before you run the test

3) Generate a random number and have your test run one way or the other depending on the random number

https://support.smartbear.com/viewarticle/54645/

4) Have your test read the value from a spreadsheet or a text file and edit the value before you run the test.

https://support.smartbear.com/testcomplete/docs/reference/program-objects/ddt/index.html


Marsha_R
[Community Hero]
____
[Community Heroes] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Heroes]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Hero] signature is used with permission by SmartBear Software.
https://community.smartbear.com/t5/custom/page/page-id/hall-of-fame

View solution in original post

sonya_m
Community Manager

Re: How can I initialize parameters for my keyword test before running the Keyword test.

Thanks a lot for such an informative answer Marsha!

 

@vsumathi does this answer your question?


Sonya Mihaljova
Community and Education Specialist

Did my reply answer your question? Give Kudos or Accept it as a Solution to help others. ⬇️⬇️⬇️
cancel
Showing results for 
Search instead for 
Did you mean: