Skip to main content

QTP Certification Exam Papers

Practice Questions for Exam: HP0-M16
Title: HP QTP 9.2 Software

QUESTION 1
When a procedure is created in the Function Library editor, what is the extension on
the file?
A. .INI
B. .TXT
C. .QFL
D. .VBS
QUESTION 2
What are the categories in the Step Generator?
A. Object, Operation, Value
B. Library, Built-in, Local Script
C. Operation, Arguments, Return Value
D. Test Objects, Utility Objects, Functions
QUESTION 3
In Test Settings ->Run the Data Table iteration options are for which data sheet?
A. Local
B. Global
C. Run-time Data Table
D. Design-time Data Table
QUESTION 4
What can you use to handle unpredictable testing exceptions?
A. A Do Loop
B. Recovery Scenario
C. IFHEN statement
D. Selectase statement
QUESTION 5
In which command can you associate a function library to a test?
A. Run Options
B. Test Settings
C. View Options
D. Function Definition Generator
QUESTION 6
HP0-M16
Where do you set the action iterations for a specified action?
A. Action Settings
B. Action Properties
C. Action Run Settings
D. Action Call Properties
QUESTION 7
Where do you mark an action as reusable?
A. Action Settings
B. Action Properties
C. Action Run Settings
D. Action Call Properties
QUESTION 8
After running a test that contains both input and output parameters, where can the
results of an
output parameter be found?
A. Local DataSheet
B. Global DataSheet
C. Run-time Data Table
D. Design-time Data Table
QUESTION 9
If you have a Virtual Object Collection stored on your machine, and you don't want to
use it, what
must you do?
A. Disable Virtual Objects in Test Settings
B. Remove the Collection from your machine
C. Disable Virtual Objects in General Options
D. Remove the Collections from the Resources list
QUESTION 10
HP0-M16
Which method for the DataTable utility object will allow you to retrieve information
from the Data
Table during a test run?
A. Value
B. Import
C. GetCell
D. GetValue
QUESTION 11
What does the source property of a database checkpoint object represent?
A. The SQL query
B. The identification number of the database
C. The number of rows returned from the query
D. The connectionstring used to connect to the database
QUESTION 12
What is created, by default, with each new action?
A. Local Data Sheet, Global Data Sheet, Folder
B. Local Object Repository, Local Data Sheet, Folder
C. Global Data Sheet, Local Object Repository, Folder
D. Local Data Sheet, Global Data Sheet, Local Object Repository
QUESTION 13
What are the available environment variable type(s)?
A. Built-in
B. User-defined
C. User-function
D. Built-in, User-defined
E. Built-in, User-function
QUESTION 14
If the Global Data sheet contains no data and the Local Datasheet contains two rows
of data, how
many times will the test iterate?
A. 1
B. 2
C. 3
D. 5
QUESTION 15
HP0-M16
What is the first thing that must be defined in a Recovery Scenario?
A. Trigger
B. Recovery Operation
C. Recovery Scenario Name
D. The Function used in the scenario
QUESTION 16
What are bitmap checkpoints sensitive to?
A. Image size and object type
B. Object type and image type
C. Screen resolution and object type
D. Screen resolution and image size
QUESTION 17
If the Local Data sheet contains two rows of data, how many times will the action
iterate, by
default?
A. 1
B. 2
C. 3
D. 5
QUESTION 18
How do you close the database session after examining the results of an SQL query?
A. Call the ADO.Close function
B. Use the close method for the RecordSet object
C. Set the RecordSet and Connection objects equal to Nothing
D. Use the close method for the RecordSet and Connection objects
QUESTION 19
What are the available trigger event types?
A. Pop-up window, object state, VBScript event
B. Object State, VBScript event, Application crash
C. Pop-up window, object state, test run error, QTP crash
D. Pop-up window, object state, test run error, application crash
QUESTION 20
What is the keyword used to define how the counter variable in a or lext loop
increments?
A. ++
B. Next
C. Skip
D. Step
QUESTION 21
What are the two most commonly used ADO objects?
A. Fields
B. Execute
C. Connection, RecordSet
D. Open, ConnectionString
QUESTION 22
How do you declare a constant?
A. Dim statement
B. Con statement
C. Const statement
D. Option Explicit statement
QUESTION 23
What method is used to retrieve the number of columns in the query results?
A. Fields.Count
B. Fields.Item(EOF)
C. Fields.Count(BOF)
D. Fields.Count.Value
QUESTION 24
To bypass the Object Repository you can:
A. Turn the Object Repository off
B. Use a programmatic description
C. Delete all objects in all repositories
D. Add the object to the Object Repository Manager
QUESTION 25
What does the ChildObjects method return?
A. A Collection object
B. A string true/false
C. A Boolean TRUE/FALSE
D. The number of objects matching the ChildObject description
QUESTION 26
What object is used to read information from a text file?
A. Read
B. ReadLine
C. TextStream
D. File System
E. Open Text File
QUESTION 27
If you are typing in Expert View and you type an object followed by a dot, what does
QuickTest
display?
A. Nothing
B. The arguments for that object
C. The methods and properties for that object
D. The child objects and methods for that object
QUESTION 28
By default, how does QuickTest pass arguments to the procedure?
A. ByVal
B. ByRef
C. ByArg
D. ByRes
QUESTION 29
What object is used to send information to test results at the completion of the test
run?
A. Result
B. Reporter
C. ReportEvent
D. ResultReport
QUESTION 30
If a procedure is defined in a test script, that procedure is accessible to which
tests/scripts?
A. Only to other procedures
B. It is not usable to any test scripts
C. The test script in which it is defined
D. Using the Step Generator, it is available to any test script
QUESTION 31
When does a Do loop statement evaluate for continuation?
A. At the end of the loop
B. At the start of the loop
C. At the start or the end of the loop
D. This loop uses a counter variable
QUESTION 32
How can you retrieve the number of items in the list for a WebList object?
A. GetList
B. GetItem
C. GetItemsCount
D. GetROProperty
QUESTION 33
What is the difference between a subroutine and a function?
A. A subroutine can call itself; a function cannot
B. A function returns a value; a subroutine cannot
C. A function can accept arguments; a subroutine cannot.
D. A subroutine can call other procedures; a function cannot.
QUESTION 34
What method is used to send a run-time Data sheet to an Excel file?
A. Send
B. Export
C. SendSheet
D. Exportsheet
QUESTION 35
What looping statements are available in QuickTest?
A. Whileend, Doloop, Ifhen
B. Switchfase, Ifhen, Fortext
C. Fortext, Whileend, Doloop
D. Fortext, Doloop, Switchase
QUESTION 36
What does the GetTOProperty method do?
A. Retrieves the value of a property from a test object
B. Retrieves the available properties from a test object
C. Retrieves the value of a property from a run-time object
D. Retrieves the available properties from a run-time object
QUESTION 37
HP0-M16
To use low-level recording, what must you do first?
A. Start a new test
B. Be in the KeyWord view
C. Be recording in Normal mode
D. Click Low Level Recording under the Automation Menu
QUESTION 38
What is the correct set of add-ins installed automatically with QuickTest 9.2?
A. NET, Web, Java
B. Web, SAP, Visual Basic
C. Active X, Visual Basic, Web
D. Active X, TE, Web Services
QUESTION 39
What information can be seen in the information pane?
A. Syntax errors
B. The test name and author
C. The QTP license information
D. The machine id and operating system
QUESTION 40
What does a breakpoint do?
A. Stops test execution at the specified step, after executing that step
B. Stops test execution at the specified step, before executing that step
C. Pauses test execution at the specified step, after executing that step
D. Pauses test execution at the specified step, before executing that step
QUESTION 41
Which of the following is an example of a missing resource?
A. An object
B. Run Results
C. A Regular Action
D. An External Action
QUESTION 42
HP0-M16
What are the available step commands in QuickTest?
A. Step, Step Into, Step Out
B. Step Into, Step Over, Step Out
C. Step Test, Step Action, Step Function
D. Run from Step, Debug from Step, Run from Step
QUESTION 43
When a test is run in update mode, what is updated?
A. The test results
B. The object descriptions
C. The action names in the test
D. The logical names in the test
QUESTION 44
What are the phases in the QuickTest workflow?
A. Plan, Record, Enhance, Run
B. Prepare, Record, Verify, Run
C. Plan, Create, Verify & Enhance
D. Prepare, Create, Verify & Enhance, Integrate
QUESTION 45
Why is low-level recording mode useful?
A. It records exact keyboard operations on an object.
B. It records exact coordinates of all mouse movements.
C. It uses the object repository to determine what methods can be used.
QUESTION 46
What are test object properties?
A. Those properties as defined in a description object.
B. Those properties as defined in Object Identification
C. Those properties displayed by an object at run-time
D. Those properties used in the Object Repository for object identification
QUESTION 47
What is the function of the Object Repository Manager?
A. Assign variable names to test objects
B. View/make/modify a Local Object Repository
C. View/make/modify a Shared Object Repository
D. Define new test objects using programmatic descriptions
QUESTION 48
Where are virtual object collections stored?
A. In a Function Library
B. In the local Object Repository
C. In the Object Repository Manager
D. Dat folder inside of the QTP installation directory
QUESTION 49
In the Object Identification dialog box, which properties can be viewed?
A. The base filter and optional properties
B. The mandatory and optional properties
C. The base filter and assistive properties
D. The mandatory and assistive properties
QUESTION 50
Where do you turn Smart Identification IN?
A. The Object Repository
B. The Test Settings dialog
C. The General Options dialog
D. The Object Identification dialog
QUESTION 51
How do you know if Smart Identification has been used in a test?
A. The Smart Identification icon appears in the test results
B. The test results will show a run error, causing a test failure
C. The properties used by the object repository will be changed
D. The Object Repository will show the Smart Identification icon
QUESTION 52
What options are available to filter objects in the Target Object Repository pane when
merging
object repositories?
A. Show all objects or Show only objects with conflicting object types
B. Show all objects or Show only objects with conflicting descriptions
C. Show only objects with conflicting logical names or Show only objects with
conflicting object
types
D. Show only objects with conflicting logical names or Show only objects with
conflicting
descriptions
QUESTION 53
What is the default ordinal identifier?
A. The location
B. The object id
C. The nativeclass
D. The index number
QUESTION 54
Which statement is used to associate a procedure with a test object class?
A. RegisterFunction
B. RegisterUserProc
C. RegisterUserFunc
D. RegisterProcedure
QUESTION 55
What must you do before a shared object repository can be edited?
A. Enable Editing
B. Add a new object
C. Open the object repository
D. Open an action that uses that shared object repository
QUESTION 56
Where do you configure an action to use a shared object repository?
A. Test Settings
B. Action Settings
C. Action Call Properties
D. Associate Repositories
QUESTION 57
You should use local object repositories when you:
A. Work with single-action tests
B. Work with multiple-action tests
C. Create multiple tests for a single application
D. Expect the test object properties to change frequently
QUESTION 58
Where can you merge two shared object repositories?
A. The Object Repository
B. The Object Repository Manager
C. The Associate Object Repositories Tool
D. You can only merge local object repositories




ANSWERS

1. c
2. d
3. b
4. b
5. b
6. d
7. b
8. c
9. c
10. a
11. a
12. b
13. d
14. a
15. a
16. d
17. a
18. d
19. d
20. d
21. c
22. c
23. a
24. b
25. a
26. c
27. d
28. b
29. b
30. c
31. c
32. d
33. b
34. d
35. c
36. a
37. c
38. c
39. a
40. d
41. d
42. b
43. b
44. d
45. a
46. d
47. c
48. d
49. d
50. d
51. a
52. b
53. a
54. c
55. a
56. d
57. a
58. b

Comments

Popular posts from this blog

PDF Automation in QTP

                                                                            The most challenging issue with PDFs is that it could be of any kind, not just a tabular data; it could have plain text, images or even forms to fill up. So this makes a tester’s life a bit difficult, never mind, we will definitely find an easy of do it… Although there are already some better approaches we have to deal with PDF documents but I found many of us are facing so many difficulties using this. There are lots of queries coming at QTP forums asking for an easy way of doing it with PDFs. keeping those in my mind I started c...

Convert JSON to XML using QTP/UFT/VBScript

Sample Code : Dim strPage,strJSON,objIE strPage = "C:\Jay\JLoader.html" Set objIE = CreateObject("InternetExplorer.Application") objIE.Visible = True objIE.Navigate2 strPage While objIE.Busy : Wend strJSON = "{""FirstName"":""Jay"", ""LastName"":""Krishna""}" Set objWin = objIE.document.parentWindow objWin.execScript "var jsonStr2XML = function(strJSON) { return json2xml(JSON.parse(strJSON));};" Msgbox  oWin.jsonStr2XML(strJSON) objIE.Quit In Detail: Converting The most popular data interchange format JSON(JavaScript Object Notation) to XML using QTP/UFT. Parsing JSON in UFT could be a challenge so we will use JavaScript in UFT to make it perfect. SO We need :              Java Script API  - To Convert JSON to XML                         JavaScript Files :  ...

Download Test Resource From QC Using QTP

'########################################################################### '* Function Name: QCGetResource '* Designer: Jay '* Date 09-May-2012 '* This script will Download QC Test Resource to a local dir '########################################################################### Function QCGetResource(resourceName,saveTo)     Set qcConn = QCUtil.QCConnection     Set oResource = qcConn.QCResourceFactory     Set oFilter = oResource.Filter     oFilter.Filter("RSC_FILE_NAME") = resourceName     Set oResourceList = oFilter.NewList     If oResourceList.Count = 1 Then         Set oFile = oResourceList.Item(1)         oFile.FileName = resourceName         oFile.DownloadResource saveTo, True     End If         Set qcConn = Nothing     Set oResource = Nothi...

compare Two Text files using Vb Script

Public Function CompareFiles (FilePath1, FilePath2) Dim FS, File1, File2 Set FS = CreateObject(“Scripting.FileSystemObject”) If FS.GetFile(FilePath1).Size <> FS.GetFile(FilePath2).Size Then CompareFiles = True Exit Function End If Set File1 = FS.GetFile(FilePath1).OpenAsTextStream(1, 0) Set File2 = FS.GetFile(FilePath2).OpenAsTextStream(1, 0) CompareFiles = False Do While File1.AtEndOfStream = False Str1 = File1.Read(1000) Str2 = File2.Read(1000) CompareFiles = StrComp(Str1, Str2, 0) If CompareFiles <> 0 Then CompareFiles = True Exit Do End If Loop File1.Close() File2.Close() End Function Return value: The function returns 0 or False if the two files are identical, otherwise True. Example: File1 = “C:\countries\apple1.jpg” File2 = “C:\countries\apple3.jpg” If CompareFiles(File1, File2) = False Then MsgBox “Files are identical.” Else MsgBox “Files are different.” End If    Source: Mercury Forum’s KB articles

CreateImageFromClipBoard using QTP

'-------------------------------------------------------------------------' Method : CreateImageFromClipBoard' Author : Jai Purpose : It gets the clipboard image and convert as a image file.' Parameters: FileName - String, contains the BMP file name' iIndex - Integer, contains the Worksheet index' Returns : String. The replaced file name it gives.' Caller : - Nil' Calls : - Nil' ------------------------------------------------------------------------- Sub CreateImageFromClipBoard(sFileName) Dim wshShell,ShellReturnCode, sCmdExec Set WshShell = WScript.CreateObject("WScript.Shell") sCmdExec = "D:\autostuff\i_view32.exe /silent /clippaste /convert="& sFileName ShellReturnCode = WshShell.Run(sCmdExec, 1, True) End Sub