Friday, August 5, 2016

Interview Questions - 2

Introduction

Technical:
Questions about QTP framework
How do you add objects to a repository?
Folder structure of QTP framework
Function libraries
Write the steps how you would automate if a new page is added to your website
How good are you with databases?
Types of joins
What databases you have used?
Can you join table even if there are no primary and foreign keys are defined
Write a query to join three tables’ student, class, and school
How do you write test scripts in VSTS 2010?
What frame work did you use in VSTS?
What other tools did you use for defect tracking?
How did you do web service testing?
What is a basic error you would get when an XML is not correct?
Tell me some examples of security testing

Testing:
Testing Methodologies
Bug life cycle
Rate yourself on manual testing on a scale of 1-5?
Write the scenarios in testing a coffee vending machine
Difference between QA and testing
What kind of QA process do you follow?
What are the inputs required to raise a defect
Severity Vs Priority
High priority and low severity defect example
Checklist for testing a website
What is a test plan?
Did you ever get a chance to give the estimates and how would you do that?

Process:
Application development life cycle
Agile methodology
Who is going to assign the severity and priority?
https://drive.google.com/file/d/1PqaDGKnQwGXRik3Snt9-7t-Zfb63rMWV/view?usp=sharing

Interview Questions - 2

Introduction

Technical:
Questions about QTP framework
How do you add objects to a repository?
Folder structure of QTP framework
Function libraries
Write the steps how you would automate if a new page is added to your website
How good are you with databases?
Types of joins
What databases you have used?
Can you join table even if there are no primary and foreign keys are defined
Write a query to join three tables’ student, class, and school
How do you write test scripts in VSTS 2010?
What frame work did you use in VSTS?
What other tools did you use for defect tracking?
How did you do web service testing?
What is a basic error you would get when an XML is not correct?
Tell me some examples of security testing

Testing:
Testing Methodologies
Bug life cycle
Rate yourself on manual testing on a scale of 1-5?
Write the scenarios in testing a coffee vending machine
Difference between QA and testing
What kind of QA process do you follow?
What are the inputs required to raise a defect
Severity Vs Priority
High priority and low severity defect example
Checklist for testing a website
What is a test plan?
Did you ever get a chance to give the estimates and how would you do that?

Process:
Application development life cycle
Agile methodology
Who is going to assign the severity and priority?

What is Checkpoint in QTP? Explain the types of Check points.

Checkpoint is a method used to check the content before and after the step, i.e it is used to compare the expected value with the actual value displayed in the application, these checkpoints can be customized according to the requirements.
The checkpoint can be added while recording the application or it can be added after the recording is completed using Active screen (For adding Checkpoint after recording the Active screen must be enabled while recording)
Once the checkpoint is added, the QTP adds a checkpoint to the current row in keyword view and adds a check checkpoint statement to the expert view.
The types of checkpoint are,
  • Standard Checkpoint
The standard checkpoint checks the object property values in an application or a webpage.
It checks objects like Radio buttons, combo boxes, images, Tables, Web page properties, links etc.
The Table checkpoint can be used to check all the values in the table, it can be created by inserting standard checkpoint on the table.
The page checkpoint can also created by inserting standard checkpoint on the object, the page check point can be used to check the time taken to load a webpage.
  • Bitmap Checkpoint
The Bitmap checkpoint can be used to check an area of a webpage or an application as a bitmap. It checks that particular area by pixel to pixel comparison between actual and expected images.
  • Image Checkpoint
The Image checkpoint is used to check the properties of an image in the application or a webpage like verifying the selected image source file is correct or not.
The difference between Bitmap checkpoint and Image checkpoint is in Bitmap Checkpoint we can check the images on pixels basis where in Image checkpoint it cannot be done.
  • Text Checkpoint
The Text checkpoint is used to check the expected text from an application or a web page. It can be a specific region or a small portion of the text displayed.
  • Accessibility Checkpoint
The Accessibility checkpoint checks the areas of the web page that may not conform to the W3C (World Wide Web Consortium) Web Content Accessibility Guidelines.
  • Database Checkpoint
The Database checkpoint is used to check the database accessed by the application.
This checkpoint creates a query during record time and the database values are stored as the expected values. The same query is executed during run time and the actual & expected values are compared.
  • XML Checkpoint
The XML checkpoint checks the data content of XML documents in XML files or XML schema related to the webpage.



Step generator:

  • This is a facility that QTP provides in order to make adding programmatic steps into QTP easy for the user.
  • You can use it in the Keyword view, function library, Active screen or Expert view to generate steps
  • It can be used to write steps into a test or to a function library.
  • To launch, use the menu option “Insert->Step Generator” menu option. Right click any where you want the step to go and select “Insert Step-> Step generator” or F7(except in Active screen)
Step generator
Example:
I will explain this with a scenario: Open www.gmail.com and click on “Create Account” link. This is how this statement will look.
1Browser("Gmail: Email from Google").Page("Gmail: Email from Google").Link("Create an account").Click 
If I need to check if the link exists at all, before I write the code to click on it, I will need a step     before the above statement. This is how I do it:
Step # 1) Select the place where you need the step inserted.
a) Expert view: Place the cursor where you want the step to go and launch step generator.
b) Keyword view:  Select the step below which you want to insert the step.
c) Active screen: In the active screen window, right click and choose the step generator option. It will ask you to choose the object on which your step should be based on. Following that the step generator window is launched.
Step generator
Step #2) This is the step generator window that gets launched. Please note the details that it is displaying now. It is showing all the details related to the step that is currently chosen. We can choose the required values for the new step but that does not affect the current step.
Step generator
I am going to set the values as required by me to enable checking if the link exists.
------------
best software testing training course
Step generator
As you can see, I chose a Test Object, Create an account link and chose the operation Exist. I left the arguments empty because it is optional and chose that the return value of the operation be stored in a variable var_Exist. It displays the VB Script statement, as it is going to appear in the Expert view in the “Generated Step” field. In other words, the syntax.
Step #3) The drop down where I chose a test object, I can alternately choose to base my step on a utility object or Functions.
Step generator
Step #4) Object: this field contains a list of required object or the function library source.
Step #5) Operation field will let you choose the appropriate method, property or function.
Step #6) Arguments and Return value: These fields are self explanatory. The user could parametewise the arguments or provide constant values.
Step #7) The user can just insert one statement or choose to follow it with another one by checking the “Insert another step” option ON.
Step #8) So, back to our example. I will click OK. This is the statement that gets inserted.
1var_Exist = Browser("Gmail: Email from Google").Page("Gmail: Email from Google").Link("Create an account").Exist
2Browser("Gmail: Email from Google").Page("Gmail: Email from Google").Link("Create an account").Click

Testing - Difference between QTP and WINRUNNER

Explain the difference between QTP and WINRUNNER?

- Static and dynamic images are compared through QTP. Where as Winrunner is used to conduct the testing only on static images.

- The test scripts that are used in QTP is only one i.e., Main Test, and compiled module does not supports. Where as Winrunner supports two types of test i.e., Main Test and compiled module

- The check points are 9 in QTP, whereas there are 4 check points in Winrunner.

- Reusable actions can be created in QTP, where as Winrunner can not.

- Winrunner does not support multimedia, photoshop. On the other hand, QTP supports multimedia. QTP supports .NET and XML applications. Winrunner does not. QTP generates scripts based on VB. whereas; Winrunner generates scripts based on TSL written in C.


i prefer qtp.

I think this is sufficient for u to understand clearly.

WinRunner Compared to QuickTest Pro

Environment Coverage Comparison:

Common environments shared by both WinRunner and QuickTest Pro:
Web-Related Environments IE, Netscape, AOL
JDK, Java Foundation Classes, AWT
Symantec Visual Café
ActiveX Controls
ERP/CRM Oracle: Jinitiator, 11i, NCA
Custom Client Server Windows
C++/C
Visual Basic
Operating Systems Windows 98, 2000, NT, ME, XP
Legacy 3270, 5250 Emulators
VT100

WinRunner Only Environments:
Custom Client/Server PowerBuilder
Forte
Delphi
Centura
Stingray
SmallTalk
ERP/CRM Baan
PeopleSoft Windows
Siebel 5, 6 GUI Clients
Oracle GUI Forms

QuickTest Pro Only Environments:
ERP/CRM SAP
Siebel 7.x
PeopleSoft 8.x
.Net WinForms
WebForms
.Net controls
Web Services XML, HTTP
WSDL, SOAP
J2EE, .Net
Multimedia RealAudio/Video
Flash



Feature Comparison:

Common features found in both WinRunner and QuickTest Pro:
Record/Replay ODBC & Excel Connectivity
Code Editor & Debugger Recovery Manager
Shared Object Repository Rapid Object Import
Numerous Checkpoints Analog
Script & Function Libraries

WinRunner Only Environments:
Function Generator Database Integration
Run Wizard TSL
MDI

QuickTest Pro Only Environments:
ActiveScreen TestGuard
Tree View ScriptFusion
Data Table VBScript
Function Generator*(coming in v7.0) Run Wizard*(coming in v7.0)



What We Recommend

QuickTest Pro is our functional testing tool of choice!


Most customers are in either of two situations:
Existing WinRunner customers asking “Should we switch to QuickTest Pro?”
New customers asking “Which should we get, WinRunner or QuickTest Pro?”

We have been implementing Mercury’s products since 1992 and have senior level expertise in WinRunner. We have been implementing WinRunner since the very first version of it. So like many existing WinRunner customers we have a huge knowledge investment in WinRunner ourselves. However we have worked on the Mercury development team on the QuickTest Pro 6.0 and 6.5 releases, and have solid real-world experience in implementing QuickTest Pro since the 6.0 release. We have found it to be a great tool to use and recommend it to all customers! Overall, we recommend using QuickTest Pro unless for some reason you have to use WinRunner due to an unsupported environment not existing in QuickTest Pro.

Overall, QuickTest Pro is easier to use and implement for both technical and non-technical testers in comparison to WinRunner. QTP offers many features that are found in WinRunner, but are easier to use. QTP also offers many features not found in WinRunner that make test script creation, enhancement and maintenance easier.

Let’s quickly discuss some key issues:
The WinRunner interface forces the user to look directly at TSL code. TSL is the WinRunner programming language developed by Mercury. It is based on the “C” programming language and therefore looks very similar. For testers who do not have a technical background, they are not always comfortable with having to always look at code. However QuickTest Pro offers a “Tree View” which is an icon-based view of the script. This is very easy to get used to and non-technical people adapt to it quicker and feel more comfortable working with it. For the technical user, they can always switch over to the “Expert View” in QuickTest and look directly at code, and program away using VBScript.
WinRunner uses TSL which is a proprietary language of Mercury. These types of languages can be very restrictive and you are limited on available resources. QuickTest Pro use the Microsoft programming language VBScript which is very powerful, has lots of capabilities and there are lots of resources available.
We feel that there are many more “point and click” features in QuickTest Pro than WinRunner. This makes its use easier.
All the same features found in WinRunner are found in QuickTest Pro plus more.
Data Table integration is much easier and simpler with QuickTest Pro.
Data Driven Testing is easier with more options in QuickTest Pro.
Script enhancements are typically easier with QuickTest Pro because it has the Active Screen where the windows and objects in your application are captured for later use. Using a “point and click” capability you can easily interface with objects, their definitions and create checkpoints after having recorded a script – without having to navigate back to that location in your application like you have to with WinRunner. This greatly speeds up script development.
QuickTest Pro currently has built in integration with WinRunner in order to be able to call existing scripts, which is great for customers who already have a large test script investment with WinRunner. Likewise WinRunner 8.0 is to have the ability to also call QuickTest Pro scripts. This eases the transition from WinRunner to QuickTest Pro for existing customers.
Parameterization is much easier in QuickTest Pro and basically anything in QuickTest Pro can be parameterized (statements, checkpoints and the Object Repository).
Capturing various output values is easier and simpler with QuickTest Pro. Using this capability with parameterization enables you to easily develop scripts that can do more in regards to testing.
We have been implementing QuickTest Pro in real-world environments and have found it much easier to use, advance features are easier to implement and the script development is quicker. We really enjoy using QuickTest Pro and highly recommend it as the functional testing tool to use.



QuickTest Pro is our functional testing tool of choice!



WinRunner
Summary:

This product is a mature tool that has been around since approximately 1995. It interfaces with most of the leading development toolkits using the WindowsAPI and toolkit DLLs to interface with the “Application Under Test”. 

WinRunner offers a recording feature that will watch the individual tester and generate a test script to simulate the same actions just performed. The script is displayed as a program which can be enhanced with checkpoints, logic and special coding/programming.

WinRunner also has integration with Excel spreadsheets for data driven testing and the ability to write data out in Excel format or in simple text files.

Here is the description from the Mercury “Features and Benefits” section of the WinRunner web page:
Significantly increase power and flexibility of tests without any programming: The Function Generator presents a quick and error-free way to design tests and enhance scripts without any programming knowledge. Testers can simply point at a GUI object, and WinRunner will examine it, determine its class and suggest an appropriate function to be used. 
Use multiple verification types to ensure sound functionality: WinRunner provides checkpoints for text, GUI, bitmaps, URL links and the database, allowing testers to compare expected and actual outcomes and identify potential problems with numerous GUI objects and their functionality. 
Verify data integrity in your back-end database: Built-in Database Verification confirms values stored in the database and ensures transaction accuracy and the data integrity of records that have been updated, deleted and added. 
View, store and verify at a glance every attribute of tested objects: WinRunner's GUI Spy automatically identifies, records and displays the properties of standard GUI objects, ActiveX controls, as well as Java objects and methods. This ensures that every object in the user interface is recognized by the script and can be tested. 
Maintain tests and build reusable scripts: The GUI map provides a centralized object repository, allowing testers to verify and modify any tested object. These changes are then automatically propagated to all appropriate scripts, eliminating the need to build new scripts each time the application is modified. 
Test multiple environments with a single application: WinRunner supports more than 30 environments, including Web, Java, Visual Basic, etc. In addition, it provides targeted solutions for such leading ERP/CRM applications as SAP, Siebel, PeopleSoft and a number of others. 
Simplify creation of test scripts: WinRunner's DataDriver Wizard greatly simplifies the process of preparing test data and scripts. This allows for optimal use of QA resources and results in more thorough testing. 
Automatically identify discrepancies in data: WinRunner examines and compares expected and actual results using multiple verifications for text, GUI, bitmaps, URLs, and databases. This ensures stable functionality and execution of business transactions when the application is released into production. 
Validate applications across browsers: WinRunner enables the same test to be used to validate applications in Internet Explorer, Netscape, and AOL. This saves testing time and reduces the number of scripts that must be developed and maintained. 
Automatically recover tested applications from a crash: Unexpected events, errors, and application crashes during a test run can disrupt the testing process and distort results. WinRunner's Recovery Manager enables unattended recovery and provides a wizard that guides the process of defining a recovery scenario. 
Leverage investments in other testing products: WinRunner fully integrates with our other testing solutions, including LoadRunner for load testing and TestDirector for global test management. Moreover, organizations can reuse WinRunner test scripts with QuickTest Professional.



- WinRunner “Features and Benefits” webpage from Mercury:
Products - Mercury Functional Testing: WinRunnerâ„¢ Features 
Pros:
· Mature product that has been around since about 1995.
· Simple interface.
· Many features.
· Many consultants and user group/forums for support.
· Decent built in help.
· Fewer features to have to learn and understand compared to QuickTest Pro.
· Interfaces with the Windows API.
· Integrates with TestDirector.

Cons:
· Has basically been superceded by QuickTest Pro.
· Looking at “program code” for the test case.
· Coding is done in a proprietary language (TSL).
· Very few resources available on TSL programming (it is based on the C programming language, but is not C).
· Need to be able to program to a certain extent in order to gain flexibility and parameterization.
· Need training to implement properly.
· The GUI Map can be difficult to understand and implement.



QuickTest Pro

Summary:
QuickTest Professional provides an interactive, visual environment for test development. 

Here is the description from the Mercury Interactive “How it Works” section of the QuickTest Pro web page:
Mercury QuickTest Professional™ allows even novice testers to be productive in minutes. You can create a test script by simply pressing a Record button and using an application to perform a typical business process. Each step in the business process is automated documented with a plain-English sentence and screen shot. Users can easily modify, remove, or rearrange test steps in the Keyword View. 

QuickTest Professional can automatically introduce checkpoints to verify application properties and functionality, for example to validate output or check link validity. For each step in the Keyword View, there is an ActiveScreen showing exactly how the application under test looked at that step. You can also add several types of checkpoints for any object to verify that components behave as expected, simply by clicking on that object in the ActiveScreen. 

You can then enter test data into the Data Table, an integrated spreadsheet with the full functionality of Excel, to manipulate data sets and create multiple test iterations, without programming, to expand test case coverage. Data can be typed in or imported from databases, spreadsheets, or text files. 

Advanced testers can view and edit their test scripts in the Expert View, which reveals the underlying industry-standard VBScript that QuickTest Professional automatically generates. Any changes made in the Expert View are automatically synchronized with the Keyword View. 

Once a tester has run a script, a TestFusion report displays all aspects of the test run: a high-level results overview, an expandable Tree View of the test script specifying exactly where application failures occurred, the test data used, application screen shots for every step that highlight any discrepancies, and detailed explanations of each checkpoint pass and failure. By combining TestFusion reports with Mercury Quality Management, you can share reports across an entire QA and development team. 

QuickTest Professional also facilitates the update process. As an application under test changes, such as when a “Login” button is renamed “Sign In,” you can make one update to the Shared Object Repository, and the update will propagate to all scripts that reference this object. You can publish test scripts to Mercury Quality Management, enabling other QA team members to reuse your test scripts, eliminating duplicative work. 

QuickTest Professional supports functional testing of all popular environments, including Windows, Web, .Net, Visual Basic, ActiveX, Java, SAP, Siebel, Oracle, PeopleSoft, terminal emulators, and Web services. 

- QuickTest Pro “How it Works” webpage from Mercury:
Products - Mercury QuickTest Professionalâ„¢ - How it Works 

We like QuickTest Pro and now prefer implementing it over WinRunner. When you get into advance testing scenarios, QuickTest Pro has more options and they are easier to implement compared to WinRunner in our opinion.

Do to the similarities in concept and features, an experienced WinRunner user can easily convert to QuickTest Pro and quickly become an efficient Test Automation Engineer!

We recommend that existing customers begin all new development with QuickTest Pro and use the built-in feature of calling WinRunner scripts from QuickTest Pro for all existing WinRunner scripts that they already have. As older scripts require updates and time permits, we recommend replacing them with QuickTest Pro scripts. Eventually you will be able to convert your test script library with all QuickTest Pro scripts.
Pros:
· Will be getting the initial focus on development of all new features and supported technologies.
· Ease of use.
· Simple interface.
· Presents the test case as a business workflow to the tester (simpler to understand).
· Numerous features.
· Uses a real programming language (Microsoft’s VBScript) with numerous resources available.
· QuickTest Pro is significantly easier for a non-technical person to adapt to and create working test cases, compared to WinRunner.
· Data table integration better and easier to use than WinRunner.
· Test Run Iterations/Data driving a test is easier and better implement with QuickTest.
· Parameterization easier than WinRunner.
· Can enhance existing QuickTest scripts without the “Application Under Test” being available; by using the ActiveScreen.
· Can create and implement the Microsoft Object Model (Outlook objects, ADO objects, FileSystem objects, supports DOM, WSH, etc.).
· Better object identification mechanism.
· Numerous existing functions available for implementation – both from within QuickTest Pro and VBScript.
· QTP supports .NET development environment (currently WinRunner 7.5 does not).
· XML support (currently WinRunner 7.5 does not).
· The Test Report is more robust in QuickTest compared to WinRunner.
· Integrates with TestDirector and WinRunner (can kick off WinRunner scripts from QuickTest).
Cons:
· Currently there are fewer resources (consultants and expertise) available due to QTP being a newer product on the market and because there is a greater Demand than Supply, thus fewer employee/consulting resources.
· Must know VBScript in order to program at all.
· Must be able to program in VBScript in order to implement the real advance testing tasks and to handle very dynamic situations.
· Need training to implement properly.
· The Object Repository (OR) and “testing environment” (paths, folders, function libraries, OR) can be difficult to understand and implement initially.