Executing more than one testcase. suppose in first testcase has one functions that is returning some string value. How to use first test case value into second test case?
Submitted by: AdministratorAnswer1:
At the top testcase , to declare something like:
create a global variable gPersonReferenceNumber and pass this into testcases as required.
void TestScriptSetup()
SetAppState ("YOURAPPSTATE")
gPersonReferenceNumber = CreateMinimalTestPerson()
testcase CallGlobalReference() appstate none
string sPersonString = gPersonReferenceNumber
etc
TestScriptSetUp() will be ran prior to CallGlobalReference. You can also include this into your recovery system if need be.
CreateMinimalTestPerson() returns a string value related to PersonID or whatever you would require
Answer2:
1. Use some public (global) variables to store your value
2. Writed testcase to return values, whatever you want and use it in later testcases..
Answer3:
To put it into an ini file or the registry.
Answer4:
Set the values in environment variables by SYS_SetEnv () and use them by SYS_GetEnv () wherever, whenever you want......Global variables also do this, but when you call the test cases from a plan file, global variables get reset......
Other alternative are to store them in a file and use them .
Submitted by: Administrator
At the top testcase , to declare something like:
create a global variable gPersonReferenceNumber and pass this into testcases as required.
void TestScriptSetup()
SetAppState ("YOURAPPSTATE")
gPersonReferenceNumber = CreateMinimalTestPerson()
testcase CallGlobalReference() appstate none
string sPersonString = gPersonReferenceNumber
etc
TestScriptSetUp() will be ran prior to CallGlobalReference. You can also include this into your recovery system if need be.
CreateMinimalTestPerson() returns a string value related to PersonID or whatever you would require
Answer2:
1. Use some public (global) variables to store your value
2. Writed testcase to return values, whatever you want and use it in later testcases..
Answer3:
To put it into an ini file or the registry.
Answer4:
Set the values in environment variables by SYS_SetEnv () and use them by SYS_GetEnv () wherever, whenever you want......Global variables also do this, but when you call the test cases from a plan file, global variables get reset......
Other alternative are to store them in a file and use them .
Submitted by: Administrator
Read Online SilkTest Job Interview Questions And Answers
Top SilkTest Questions
☺ | How to search for html link? |
☺ | How to read .xls file contents without using the ddt wizard? |
☺ | Need help regd. silk test runing thr .bat file on cmd prompt? |
☺ | How to launch 2 web application windows simultaneously thru Silktest? |
☺ | Can SilkTest run on Mac? |
Top Application Program Categories
☺ | AutoCAD Interview Questions. |
☺ | Microsoft Office Interview Questions. |
☺ | Microsoft Outlook Interview Questions. |
☺ | Microsoft Excel Interview Questions. |
☺ | WPF Interview Questions. |