SilkTest

  Home  Applications Programs  SilkTest


“SilkTest Interview Questions and Answers will guide us now that SilkTest is an automation tool for testing the functionality of enterprise applications in most versions of Windows, Solaris 9 and 10, and Red Hat Enterprise Linux WS 2.1 and 3.0, s learn SilkTest or get preparation for the job of SilkTest with the help of this SilkTest Interview Questions with Answers guide”



146 SilkTest Questions And Answers

81⟩ How can I get password in SilkTest?

[I have one web page after filling the information I will get a password to the respective user maild id provided in the registration page...if I want continue next scenario that password is needed.... how can I follow... the steps... I have to take that password from database itself.. or what else...]

If it's a good database schema, the database will be encrypted so that won't work. You will have to query the mail server and retrieve the information from there instead.

telnet mailserver 110

user {mailUserName}

pass {mailUserPassword}

retr 1

// this assumes that there's only one message there dele 1

 147 views

83⟩ SilkTest vs. Visual Test?

It really depends on what you are testing. For complex web sites (pages not static, multiple browser windows, JavaScript), I would say SilkTest works much better.

In general, Visual Test is new to the web browser game. If it is a Win32 app that you are testing, VT is *much* faster than Silk and the code compiles down to a binary file that can easily be put on diffrent test systems. This is a *big* plus for Visual Test.

SilkTest will make the declaration file for you, so this saves allot of time. In VT, you have to make the declarations yourself, but if the product isn't huge, this isn't a big deal.

SilkTest also is great a capturing text on a page (either web or Win32 based). VT, last I checked, lacked this function. It is a useful function for verification.

SilkTest also has a nice verification function that it makes (a few keystokes and it's done). Real easy to change some of the hardcoded data here with data from a text file or other place. Nice for doing report verification where the layout is the same, but the data is diffrent.

Cost is another big issue. SilkTest is low in price, Silk quite high.

So, again, it depends on your needs, what and how you will be testing it.

 153 views

84⟩ How to define new testplan attributes?

1. Make sure your test project is open.

2. Click Testplan/Define Attributes menu. The Define Attributes dialog box shows up. You should see 3 predefined default attributes: Category, Component, and Developer.

3. Click the New button. The New Attribute dialog box shows up.

4. Enter a name for your new attribute. For example: "Level" to indicate the complexity level of test cases.

5. Select an attribute type: Normal, Edit, or Set.

6. Click OK.

 137 views

85⟩ How to assign attribute values to test cases?

1. Make sure your testplan is open.

2. Click on the test case for which you want to assign an attribute value.

3. Click Testplan/Detail menu. The Testplan Details dialog box shows up.

4. Click the Test Attribute tab.

5. Click the Component field. The dropdown list shows up with all values of "Component".

6. Select one of the values in the dropdown list.

7. Click OK.

 151 views

86⟩ When invoking the java application there the application is getting invoked

When invoking the java application there the application is getting invoked (that is silk test is able to start my java apllication) and then comes login screen but silk Test is giving error JavaMainWin not found.

Why ? it is not coming out of invoke and excuting other part of code like entering username & password to login in that application.

Answer1:

After Invoking the application, Silk waits till it can find the application...In this case the application is your java window....

Sometime it happens that after invoking, silk is unable to recognize but if you invoke manually it works fine...

Solution:

Declare a window variable and use start method.

Now you might using the code

JavaAppWindow.Invoke ()

Instead of this do the following

Window MyJavaApp

MyJavaApp.Start ("path of exe or batch file to invoke the application")

sleep (x) (x --> appropriate value)

Answer2:

window MainWin MyWin // declare as global

main ()

try ()

testcase try () appstate none

MyWin.Start(sPath)

Answer3:

When you give start command as a part of JavaMainWin, ensure that your class path is running independantly - outside the Silk. It should work fine from JavaMainWin as well.

 136 views

87⟩ How to create a test frame?

1. Make sure your Web browser is active and showing your Web application home page. Do not minimize this Web page window.

2. Make sure your test project is open.

3. Click File/New menu. The New dialog box shows up.

4. Select the Test Frame radio button.

5. Click OK. The New Test Frame dialog box shows up with a list all active Web applications.

6. Select your Web application.

7. Enter a test frame name. For example: HomeFrame.inc.

8. Review the window name. It should be the HTML title your Web application. You can rename it, if needed.

9. Click OK to close the New Test Frame dialog box.

10. Click File/Save menu.

 149 views

88⟩ What is DefaultBaseState?

The DefaultBaseState is a starting point of test project from which the Recovery System can automatically restart your test cases when test cases fail to continue.

 148 views

89⟩ I am facing a strange problem in which Agent hangs only while executing my script for the first time

I am facing a strange problem in which Agent hangs only while executing my script for the first time.

Scenario:

1. It launches the website and Clicks to download the product.

2. By the time product is downloaded in some temp. folder, Silk is waiting for installation clause is there for install window)

3. Now, as soon as this install window comes up Agent hangs(Waitforwindow clause gets stuck in Status window)

Now, I kill my application install window, stop silk. Reexecute steps 1,2,3 they all go fine.

Question:

Any ideas, what causes Agent to hang during first time execution?

Answer1:

This problem is coming because Silk agent is unable to recognise that window first time.

Try with window.exists(). If window exists then only perform remaining operations.

Answer2:

I dont think this solution(Window.Exists ()) will work out for you.

This is a bug in Silk 6.5 and resolved in Silk 7.1.0.3, If possible upgrade your Silk.

 179 views

90⟩ Problem in calling DLL functions.

[I have a DLL which contains simple functions

function1 is just returning a char value

function2 returns a Long value

function3 returns a int value

function4 returns a double value

function5 returns a float value

but when I assign a 4test variable by calling all above functions or printing the returned value it creates a problem.

Problem:

1. Not able to return the correct "char" value from dll function. it gives garbage. same problem is with function returning float . working fine for the function returning int,double.DLL is loaded properly. Using "SilkTest 6.5 International", windows-xp. Dll was created in .NET framework . Also the functions are wrapped into "C" wrapper

Above all function gives correct values when call in a .NET framework.]

Used proper SilkTest DataType ie. String corresponding to C Char type But this time Agents crashes giving error *** Error: The Agent has abnormally exited when Aborted and silk test hangs on the statement calling Dll function returning char .

Please see the sample code

[+] dll "C:partnerTEST70FrameXPressVishnu1.dll"

[ ] String ReturnChar()

[ ] float ReturnFloat()

[ ] double ReturnDouble()

[ ] long ReturnLong()

[ ] int ReturnInt()

[+] testcase DllTest()

[ String str=ReturnChar()

// hangs for ever at above statement and agent crashes

[ ] Print(ReturnInt())

[ ] Print(ReturnChar())

[ ] Print(ReturnFloat())

[ ] Print(ReturnDouble())

[ ] Print(ReturnLong())

in Dll definition of ReturnChar()

Char ReturnChar()

{

Char a='h' ;

return a;

}

 149 views

91⟩ What are the default testplan attributes?

SilkTest offers you 3 predefined default attributes:

1. Category: The type of testcase or group of testcases. For example, you can use this attributes to categorize your test groups as "Boundary value tests", "Navagation tests", etc.

2. Component: The name of the application modules to be tested.

3. Developer: The name of the QA engineer assigned to develop the testcase or group of testcases.

 148 views

92⟩ What is the standard flow of execution of a test case?

1. Starting from the base state.

2. Drive the application to the state where the expected result should occur.

3. Verify the actual result against the expected result.

4. Declare the test case as passed or failed.

5. Return to the base state.

 171 views

93⟩ How to hide all the comments from a script if required?

How to hide all the comments from a script if required? [ want to hide them when printing but still see them in the editor? want to hide them when copying]

This can't be done. You may want to contact Segue to add it as a future enhancement.

 141 views

94⟩ How to run a test case from a test script file?

A test script file can store multiple test cases. You can run a testcase from a test script file:

1. Open the test script file.

2. Select the test case in the test file.

3. Click Run/Testcase menu. The Run Testcase dialog box shows up.

4. Click the Run button. SilkTest starts to run the test case.

5. Do not touch mouse or keyboard, to avoid interrupting the test case execution.

6. SilkTest finishes executing the testcase. The Restuls window shows up with the execution result.

7. Review the execution result.

 169 views

95⟩ How to define an object verification in a test case?

While recording a test case, you can define verification points to verify UI objects:

1. Make sure you are in the process of recording a testcase.

2. Make sure the Record Status dialog box is on the screen.

3. Make sure your recording reached the Web page that has the UI object you want to verify.

4. Click the background (blank area) of the Web page. Do not click any objects on the page.

5. Press Ctrl-Alt. The Verify Window dialog box shows up. All the objects on the current Web page are listed on the Verify Window dialog box.

6. Select the object to be verified in the object list. Un-select all other objets.

7. Select the property to be verified in the property list. Un-select all other properties.

8. Click OK to close the Verify Window dialog box.

9. Continue your recording.

 176 views

96⟩ How to define values for a testplan attribute?

You must define values for a testplan before using it:

1. Make sure your test project is open.

2. Click Testplan/Define Attributes menu. The Define Attributes dialog box shows up. You should see 3 predefined default attributes and other attributes defined by yourself.

3. Select an attribute. For example, "Component". The Values box should be empty.

4. Enter a value in Add box. For example, "Catalog".

5. Click Add. Value "Catalog" should be inserted into the Values box.

6. Repeat the last two steps to add more values.

 159 views

97⟩ While (FileReadLine (hFile, sMailData)) is not doing it for each line of the input file. How do I tell it to go on to the next line and add each string to the list and add the list to the master list of list?

While (FileReadLine (hFile, sMailData)) is not doing it for each line of the input file. How do I tell it to go on to the next line and add each string to the list and add the list to the master list of list?

[+] LIST OF LIST OF STRING ParseMailFile ()

[ ] STRING sElement, sLine, sMailData

[ ] HANDLE hFile

[ ] LIST OF STRING lsMailData = {}

[ ] LIST OF LIST OF STRING llsMailData = {}

[ ] rMail Mail

[ ]

[ ] hFile = FileOpen (csDataDir+"Mail.txt", FM_READ)

[-] while (FileReadLine (hFile, sMailData))

[ ] ListAppend(lsMailData, GetField(sMailData, ",", 1))

[ ] ListAppend(lsMailData, GetField(sMailData, ",", 2))

[ ] ListAppend(lsMailData, GetField(sMailData, ",", 3))

[ ] ListAppend(lsMailData, GetField(sMailData, ",", 4))

[ ] ListAppend(lsMailData, GetField(sMailData, ",", 5))

[ ] ListAppend(lsMailData, GetField(sMailData, ",", 6))

[ ] ListAppend(lsMailData, GetField(sMailData, ",", 7))

[ ]

[ ] ListAppend(llsMailData,lsMailData)

[ ]

[ ] FileClose (hFile)

[ ] return llsMailData

[ ]

Just force it to start from first raw before the loop. Should go through each lines.

 174 views

98⟩ What is DBTester?

DBTester is a testing tool that allows you to access a database server directly through ODBC drivers. If your application is a database driven application, you can perform a test through the application UI, and verify data changes in the database with DBTester without using the application UI.

 154 views

99⟩ How to create group and sub group descriptions in a testplan?

In a testplan, each text line starting from column 0 represents a top level group description. To create sub group description:

1. Move the cursor the next line below the top level group description.

2. Click Outline/Move Right.

3. The text line will be indented to the right to be come a sub group description.

 144 views

100⟩ Uploaded the image of the application

Uploaded the image of the application.Its MS Project Application. In that the marked portion silk recognizes as a ChildWin.

But the statement ChildWin3.SetActive() fails saying that the windowcan not activated. What is the solution ?

Try with parent window combination: Parent.ChildWin3.setActive()

 145 views