Software Testing
Wednesday, January 15, 2014
Basic VBScript For QTP
As you all know 80% of coding in QTP is through VB Scripting.So here i will be explaining basic functions in VBScripting.
DataTypes
The Primary Data type of VB Script is Variant.But it has many subtypes.The major sub types are Boolean,Byte,Currency,Date,Integer,Long,String.Functions to convert from one datatype to another is present.We will discuss about those conversion functions in later sections.
Dim
Unlike Java or C it is not necessary to declare a variable before using it in VBS.It will not throw an error if we are using a variable without declaring.To declare a variable the keyword used is Dim.
Syntax:Dim variable_name
Option Explicit
Option Explicit can be used to force declaration of the variable.this should be the first non-comment line of the script.On using the OptionExplicit ,every variable should be declared using the Dim keyword.On Failure of this the system will throw an error."Variable is undefined".
Syntax:Option Explicit
Dim num
Another important aspect which we need to keep in mind is VBS is not a case sensitive language.
So the following statements will display the result Test
Option Explicit
Dim st
ST="Test"
msgbox(ST)
Saturday, April 21, 2012
Defect Life Cycle
Wednesday, March 28, 2012
Database Testing
1. Create your own Queries
In order to test the DB properly and accurately, first of all a tester should have very good knowledge of SQL and specially DML (Data Manipulation Language) statements. Secondly, the tester should acquire good understanding of internal DB structure of AUT. If these two pre-requisites are fulfilled, then the tester is ready to test DB with complete confidence. (S)He will perform any CRUD operation from the UI of application, and will verify the result using SQL query.
This is the best and robust way of DB testing especially for applications with small to medium level of complexity. Yet, the two pre-requisites described are necessary. Otherwise, this way of DB testing cannot be adopted by the tester.
Moreover, if the application is very complex then it may be hard or impossible for the tester to write all of the needed SQL queries himself or herself. However, for some complex queries, tester may get help from the developer too. I always recommend this method for the testers because it does not only give them the confidence on the testing they have performed but, also enhance their SQL skill.
2. Observe data table by table
If the tester is not good in SQL, then he or she may verify the result of CRUD operation, performed using GUI of the application, by viewing the tables (relations) of DB. Yet, this way may be a bit tedious and cumbersome especially when the DB and tables have large amount of data.
Similarly, this way of DB testing may be extremely difficult for tester if the data to be verified belongs to multiple tables. This way of DB testing also requires at least good knowledge of Table structure of AUT.
3. Get query from developer
This is the simplest way for the tester to test the DB. Perform any CRUD operation from GUI and verify its impacts by executing the respective SQL query obtained from the developer. It requires neither good knowledge of SQL nor good knowledge of application’s DB structure.
So, this method seems easy and good choice for testing DB. But, its drawback is havoc. What if the query given by the developer is semantically wrong or does not fulfill the user’s requirement correctly? In this situation, the client will report the issue and will demand its fix as the best case. While, the worst case is that client may refuse to accept the application.
Tuesday, March 27, 2012
Graphical User Interface(GUI) Testing
- Start Application by Double Clicking on its ICON
- The Loading message should show the application name, version number, and a bigger pictorial representation of the icon.
- The main window of the application should have the same caption as the caption of the icon in Program Manager
- Closing the application should result in an "Are you Sure" message box
- Attempt to start application Twice.This should not be allowed - you should be returned to main Window
- Normally F1 button is used for help. If your product has help integrated, it should come by pressing F1 button
Friday, March 23, 2012
Software Testing Interview Questions
- What are the differences between SDLC and STLC?
- What is Agile Methodology?
- If you find a bug and the developer says No,then what will you do in this situation?
- What will you do if you get a single line bug?
- What all do you have in a Test Plan Template ?
- What are the contents in a Bug Report Template
- Explain Bug Life Cycle?
- Write 3 Test cases of MS-Excel and MS Word
- What is white box testing?
- What is usability testing?
- What is the difference between validation and verification?
- What is the difference between Quality Control and Quality Process?
- What is the Difference between Usability testing and UserInterface Testing?
- What is negative testing?
- What is Regression testing?
- What is Re-testing?
- What are the different levels of testing?
- What are the different testing techniques?
- What is priority?
- What is severity?
- Give an example of a high priority ,low severity bug?
- Give an example of a high severity,low priority bug?
- Who closes a bug?
- What is boundary value analysis?
- Explain the V-model?
- What is the difference between a requirement and an Usecase?
Thursday, March 22, 2012
Basics of software Testing
- Increased complexity of softwares
- Unclear Requirement specificatons
- Programming errors
- Poor Knowledge transfer
- Deadlines
- Testing shows presence of defects :-testing cannot prove that the software is defect free. Even if no defects are found,its not a proof of correctness.Testing only reduces the probability of undiscovered defects in the software
- Exhaustive testing is imposible :-Exhaustive testing means executing a program with all possible combination of inputs or values of program variables.Testing everything is not feasible and is impossible.
- Early Testing:-Finding defects early will reduce the cost so need to introduce testing in the early stages of SDLC .
- Defect Clustering:-A small number of modules usually contains most of the defects discovered during testing.
- Pesticide paradox:-If the same tests are executed over and over again ,eventually the same set of test cases will no longer find any new defects.To overcome this,test cases need to be regularly reviewed and revised.
- Testing is Context dependent:-Testing is done differently in different context
- Absence of Error fallacy:-Finding and fixing defects does not help if the system built is unstable.