You are on page 1of 17

SRM UNIVERSITY

DEPARTMENT OF COMPUTER APPLICATIONS

LESSON PLAN FOR LAB

TITLE : MC0715 - SOFTWARE TESTING AND QUALITY ASSURANCE

CLASS : III MCA A, B ,C & D

Ex. No. of hours Outcome


Exercise Name
No. required

1. Learn the procedure for


Overview of QTP 2
Functional Testing

Learn to generate and run Test


2. Record and Replay 2 Scripts repeatedly for
Regression Testing

Learntocheckthebehaviorof
3. Parameterization 2
TestScriptsforMultipledata

4. Learn how to do
Synchronization 2
synchronization of Test Cases

Enables to add check points to


5. Checkpoints 2 Test Cases to know the current
state of the object

Learntotesttherecovery
6. RecoveryScenarioManager 2 mechanismforthespecified
scenario

Know to test Web application


7. Testing web application 2 for no. of links, no. of images,
load time, web buttons etc.

8. Identify Business Scenarios for Learn to do Manual Testing by


2
Employee Login Form writing own Test Cases

9. Independent Test cases for Students Learn to write own Test cases
2
University Result System and do Manual Testing

Staff Incharge HOD / MCA

1. K. SENTHIL KUMAR

2. B. PRIYADHARSHINI

3. R. THENMOZHI

4. S. KAVITHA
1. OVERVIEW OF QTP
Mercury quick test professional is one important comedy of HPs quality center.
It consists of a number of software packages and tools for handling the computer software
development life cycle.
From requirements management to maintenance of the software.
These components of quality center include mercury test director for the test process management as
well as mercury win runner and mercury quick test professional for functional testing.
QTP most popular tools for functional / regression testing.
FEATURES OF QTP
QTP can be used to test a variety of applications such as .NET,J2EE,Web services,CRM and
ERP etc.
It has the record/replay provision to record the user interactions with the application software.
It uses VB script as the scripting language. Since the syntax is very similar to visual basic,
learning this scripting language is very easy.
The keyword driven testing feature provides a facility to build tests without writing the scripts.
It provides checkpoints option. using checkpoints you can verify whether the expected result and
the actual result are the same
It provides a facility for synchronization of test cases.
Object repository manager helps in ensuring that if a changes is made in one object, that changes
is reflected in all the tests that refer that object (ex:-changing the name of a button from login to
sign in).
Its auto-documentation feature provides the feature of creating test documentation
automatically.
It supports Unicode and hence you can test applications written for any of the world languages ,
such as hindi,Japanese,Chinese,etc
QTP can be integrated with win runner-test script of one tool can be used with the other. The test
results also can be shared between the two tools.
QTP has a recovery manager and, in case, the application halts due to an error, it will
automatically recover this is very useful for unattended testing.
Test report data is stored in documented XML format. This facilities transferring the report data
to another third party tool or into HTML web page.
Using special add-in modules , you can use QTP for testing a variety of applications,such as:
1. ERP/CRM Packages, such as sap, Siebel , people soft , oracle.
2. .Net webforms , winforms, .Net controls.
3. Web service applications, such as protocols, including XML,SOAP,WSDL,J2EE,and
.NET.
Multimedia applications, such as real audio/video and flash.
2. RECORD AND REPLAY

AIM:

To record and replay the test cases using calculator application.

PROCEDURE:

STEP:1 start-programs-quick test professional-quick test professional.

This displays an add-in-manager window prompting you to select the add-ins to be loaded.

STEP:2 when you click the ok button ,QTPs welcome screen is displayed prompting you to select the one
of four options.

TUTORIAL

START RECORDING

OPEN EXISTING

BLANK TEST

STEP:3 select the blank test option to create new test case.

STEP:4 click the record button to start recording.

STEP:5 select the windows applications tab.

STEP:6 click the add button (+) to select the application.

STEP:7 select the application and working folder using browse button (....).

STEP:8 then click the ok button. The selected application is added to the application details.

STEP:9 click on apply button and ok.

STEP:10 give necessary inputs.

STEP:11 once the recording is over, click the stop button.

STEP:12 save the test case:

File -save

Or

Click Save button

STEP:13Run the test case.

STEP:14 select the folder where the test results are to be stored by clicking on browse button(...) and then
click the ok button.

STEP:15 The test results get displayed in the test result window. The test result of the recorded test case can
be any of the following. done, warning, passed, failed.
OUTPUT:
3.PARAMETERIZATION:

AIM:

To parameterize the given test case.

PROCEDURE:

STEP:1 To start recording follow the basic steps.

STEP:2 Open the calculator application and start recording.

STEP:3 Press any number. The entered value will be displayed in the edit box only through keyboard.

STEP:4 click + on the calculator using mouse.

STEP:5 Press another number. This will also be keyboard input.

STEP:6 Click = on the calculator using mouse.

STEP:7 The result will be displayed in the edit box of the calculator.

STEP:8 Once recording is over , click stop button.

STEP:9 Save the test case. File -save or click save button. Now lets create the data table to parameterize
the test case.

STEP:10 Double click the data table first column A to assign a name to it. The change parameter names
dialog is displayed.

STEP:11 enter any name as data column name and click on ok.

STEP:12 Repeat step 10 and 11 for the second column and so on if needed.

STEP:13 Enter the values in the table.

STEP:14 Now we need to parameterize the Edit object with these data table columns.

STEP:15 Select the first edit box entry in the keyword view of the test case.

STEP:16Click on value columns modify button to modify the value. Instantly the value configuration
options dialog opens.

STEP:17 The constant radio button is selected by default. Select the parameter radio button and choose
the data table option from drop down list.

STEP:18 select the parameter name from name drop down list box.

STEP:19 Repeat steps 15-19 for second edit object.

STEP:20 Run the test case.


OUTPUT:
4.SYNCHRONIZATION:

AIM:

To synchronize the test cases.

PROCEDURE:

STEP:1 Start recording the test case as described previously.

STEP:2 Follow all the necessary parameterization steps.

STEP:3 Select insert step-step generator.

STEP:4 Click on the select object button to get the required object for adding the synchronization point
.This displays the select object for step.

STEP:5 To add the edit object from the calculator application, click on select object button. The mouse
pointer will be changed to a hand pointer and the QTP environment is minimized.

STEP:6 Click on the edit box of the calculator application, so that the object selection dialog is displayed.

STEP:7 This dialog prompts you to select the object on which the synchronization point has to be created.
As indicated in this dialog, if the location you clicked is associated with several objects,you need to select
the required object.Click ok.

STEP:8 Instantly the step generator dialog is displayed.Select the operation as wait property. Also
select the required property name and value.

STEP:9 Now enter the maximum time out value and click ok to proceed.

STEP:10 The wait property statement will be inserted into the keyword view.If any changes are to be
made , such as changing the time out time select the expert view which displays the vb script for the
recorded action and change the time out time to the required value.

STEP:11 Now run the test case by clicking the run button or bu selecting automation-run menu option.
OUTPUT:
5.CHECKPOINTS

AIM:

To insert standard checkpoints.

PROCEDURE:

STEP:1 Perform the basic steps for recording. After pressing the 1/x button the result is displayed in the
edit box. As we have not done any operation on the edit box so far, we dont have the reference of edit box
in our object repository(only 4 and 1/x will appear in object repository). So first of all we have to bring it to
the object repository.

STEP:2 Click on record button to start recording and add the check point to this case. This opens the
calculator application.

STEP:3 Click the next row of 1/x item, so that you can see another option <select an item> in the drop
down list.

STEP:4 Click on the <select an item> option.

STEP:5 Since there is no item as such as edit except 1/x and 4 , select object from repository. The
select object for step dialog will be displayed.

STEP:6 Click on plus node (+) to extend the calculator object tree in the select object for step dialog.
This displays 1/x and 4 as objects.

STEP:7 Click on the select object button to add the edit object from the calculator application. The
mouse pointer changes to hand pointer, minimizing the QTP environment.

STEP:8 Click on the edit box of the calculator application so that the object selection dialog will be
displayed with the object reference of the calculator.

STEP:9 Select win edit:edit and then click ok,so that the selected object will be added to the calculator
object repository list.

STEP:10 Select edit object and then click ok . You will see that the edit item is added to the current test.

STEP:11Now stop recording . You will see that the edit object is added to the object repository. Now we
need to add the standard checkpoint to it. So read along.

STEP:12 Right click on the edit item and select the insert standard checkpoint option.

STEP:13 On selection of insert standard checkpoint option, checkpoint properties dialog is displayed.

STEP:14 By default, enabled and text properties are checked. So uncheck the enabled property and
change the text property value to 0.25(since the value of is 0.25).

STEP:15 Enter checkpoint timeout as 10 seconds and select the after current step option for insert
statement. Once all the properties are chosen the checkpoint properties displayed.

STEP:16 Finally click on ok. The various steps for executing the test cases are displayed.
STEP:17 Select the third statement as indicated and right click on it . No use of third statement so better to
delete it.

STEP:18 Then select the delete option from the popup menu. So that it displays the dialog.

STEP:19Click on delete step buttonso that the selected statement is deleted. Once deleted the test case
keyword view will be shown.

STEP:20 Save and run the test case. You will notice that the results status shows failed.

OUTPUT:
6.RECOVERY SCENARIO MANAGER

AIM:

Using recovery manager test the internet explorer.

PROCEDURE:

STEP:1 Open the internet explorer. Type the wrong URL in space bar. Open QTP and select the resources.

STEP:2 Click recovery scenario manager. Recovery scenario window will be opened. Select new scenario
icon from that.

STEP:3 New scenario wizard has been opened. Click next.

STEP:4 Select object state and click next.

STEP:5 Select hand symbol. Internet explorer will be opened.

STEP:6 New object select window will be displayed. Click ok and next.

STEP:7 You will get recovery option. Click open. Select close application process and click next.

STEP:8 Select iexplorer.exe . Double click on that. Again you will get new box explorer.exe. click next.

STEP:9 Deselect add another recovery . click next and select stop the test run. Click next.

STEP:10 Give scenario name as SCI. Click next and add scenario default settings. click finish.

STEP:11 Click save and save the file in any folder of yours.

STEP:12 Now go to file-settings-click + symbol and click browse button. Now open the file that you
have saved.

STEP:13 In active scenario manager click on on every step -apply-ok.

STEP:14 Record -web-click record and run. Click ok. Again click the wrong URL. Stop the process
and run the process.
OUTPUT:
7. TESTING A WEB APPLICATION

AIM:

To test web application.

STEP:1 Perform steps 1 to 10 as explained in test case 1.

STEP:2 Start the recording process.click the record button. The record and run settings dialog is
displayed.

STEP:3 Select web tab, if it is not already selected.

STEP:4 Select the open the following address when a record or run session begins radio button.

STEP:5 Enter the URL of your web site in combo box . You need to enter the URL as
http://localhost/WeatherIndia/weather/main1.html.

STEP:6 Select Microsoft internet explorer option from open the following browser when a run session
begins drop down list.

STEP:7 Check the two check boxes- do not record and run on browsers that are already open and close
the browser when the test closes.

STEP:8 Click the ok button. The , record and run settings dialog gets closed and weather India web site
opens is Microsoft Internet explorer.

STEP:9 In the weather India web site, do the following actions

Click weather basics link

Click top link

Click clouds link

Click top link

Click weather phenomenon link

Click Earth Quake link

STEP:10 Stop the recording process by clicking the stop button.

STEP:11 Save the test script and look at the keyword view of the test case. Let us now insert the standard
checkpoint to check the number of links in the current page and the URLs.

STEP:12 Right click the weather India-Home item. A popup menu is displayed.

STEP:13 Select the insert standard checkpoint option from the pop up menu. Instantly the page
checkpoint properties dialog is displayed.
STEP:14 All the options are selected , by default. Uncheck all of them, except number of links check box
from class group box. The option, number of links, displays the number of links observed during the
recording phase in the selected page.

STEP:15 All check boxes are selected in all objects in page group box,by default uncheck images and
broken links.

Checkboxes in the page checkpoint properties.

STEP:16 Click on the filter link check... button from all objects in page group box. The filter link
check dialog is displayed.

STEP:17 Select the link and change the Link URL to the expected URL.

STEP:18 Finally click the ok button.

Check the required Link names.

STEP:19 Save the test script and run it.

STEP:20 You can view the results by exploring the test weather summary node.

OUTPUT:
MANUAL TESTING
8.LOGINPAGE:

TEST TEST TEST TEST INPUTS TEST


CASE ID DESCRIPTION PREREQUISITE RESULTS
1. USERNAME Should preceed Santhiya Accepted
with capital letter
followed by small
case
2. USERNAME Should contain Sandy123 Error
only alphabets
3. USERNAME Special characters #sandy Error
not allowed
4. USERNAME Should not 123santhiya Error
preceed with
digits
5. USERNAME Blankspace or tab Santhiya sandy Error
not allowed
6. PASSWORD It should contain Santhiya Accepted
minimum 8
characters
7. PASSWORD Combination of Sandy123#$ Accepted
digits and
alphabets with
special characters
allowed
8. PASSWORD Should not #santhiya Error
preceed with
special characters
9. PASSWORD One digit and one Sandy1best# Accepted
alphabet is
compulsory
10. PASSWORD Should not exceed Sandyborntowinamthebest Error
16 characters
11. SUBMIT Click once to Single click Accepted
login
12. SUBMIT Double click ,no Double click No action
action will be
performed
13. SUBMIT Moving the cursor Move the cursor on button Button
towards button , it highlighted
gets highlighted
14. CANCEL Single click ,login Single click Cancelled
gets cancelled
15. CANCEL Double click,no Double click No action
action will be
performed
16. CANCEL Moving the cursor Move the cursor on button highlighted
on
button,highlights
it

9. UNIVERSITY RESULT:

TEST CASE TEST TEST TEST INPUT TEST


ID DESCRIPTION PREREQUISITE RESULT
1. NAME Should contain only Santhiya Accepted
alphabets
2. NAME Should not contain @san#thiya Error
special characters
3. NAME Digits not allowed Santhiya123 Error

4. NAME Preceed with upper Santhiya Accepted


case
5. NAME Should not preceed santhiya Error
with lower case
6. REGNO Maximum 10 digits 3521010169 Accepted
allowed
7. REGNO Should be San352169 Accepted
alphanumeric
8. REGNO No tab or San 352 169 Error
whitespace
9. REGNO Special characters #35210169 Error
not allowed
10. REGNO Should not be Error
empty
11. MARKS Should not contain 78.99 Error
floating point
12. MARKS Limit should be 90 Accepted
within 0 to 100
13. MARKS Three digit greater 1)100 Acceptd
than 100 not 2)1456 Error
allowed
14. MARKS Only integers 78 Accepted
allowed
15. MARKS Alphabets not A89 Error
allowed
16. GRADE Includes alphabet A Accepted
A,B,C,D,E,F,U
17. GRADE Contains A+ Accepted
combination of
A,B,C,D,E,F,U with
+ and -
18. GRADE Digits not allowed A5 Error
19. OK Single Click Accepted
click,detailsaccepted
20. OK Double click,no Double click No action
actions performed
21. OK Moving the cursor Move the Highlighted
on button highlights cursor
it
22. CANCEL Single click,details Click Accepted
cleared
23. CANCEL Double click,no Double click No action
actions will be
performed
24. CANCEL Move the cursor on Move the Button
button highlights it cursor highlighted

You might also like