Software Testing

1. Software Testing Intro 2. What is Testing 3. Why Software Testing necessary 4. Role of Testing 5. General Testing Principles 6. Types of Software Testing 7. Load,Performance & Stress Test 8. Software Development Process 9. Project/System Life Cycle 10. Difference between terms 11. Manual V/s Automated Testing 12. Economic of Bug/Error/Fault 13. Fundamental Test Process 14. Software Testing Tools 15. Intro.to HP- QTP 16. Installing QTP 9.2 17. Ex.01 Evaluating AUT 18. Ex.01 Answer 19. Ex.02 Learning AUT 20. QTP 9.2 / 10 21. QTP Window Layout 22. Test Object Model 23. Applying Test Object Model 24. Object SPY & Object Properties 25. Designing Test 26. Ex.03 Record & Running a Test 27. Ex.03 Answer 28. Saving a Test 29. Printing a Test 30. App. Record & Run Options 31. Ex.04 Sample Web Site 32. Web Record & Run options 33. Ex.05 Recording a Test 34. Working with Keyword View 35. Keyword View Description 36. Recorded Object Hierarchy 37. Ex.06 Identifying Objects 38. Ex.06 Answers 39. Keyword view columns 40. Microsoft VBScripting 41. Running VBScript 42. Msgbox Function 43. Variable 44. VBScript and QTP 45. Print statement 46. InputBox function 47. Operator Precedence 48. Cint( ) function 49. Data Types 50. VarType( ) Function 51. TypeName( ) Function 52. Cbool( ) Function 53. Cbyte( ) Function 54. Cdate( ) Function 55. CDbl( ) Function 56. Cint( ) Function 57. CLng( ) Function 58. CSng( ) Function 59. CStr( ) Function 60. If Then - End If statement 61. If Then -Else-End If statement 62. If-Elseif-Else-End If Statement 63. Len( ) Function 64. Left( ) Function 65. Right( ) Function 66. Mid( ) Function 67. Ltrim(), Rtrim(), Trim() Function 68. For-Next Statement 69. Array Function 70. ABS( ) Function 71. ASC( ) Function 72. Chr( ) Function 73. Date( ) Function 74. Now( ) Function 75. DateAdd( ) Function 76. Time( ) Function 77. DateDiff( ) Function 78. InStr( ) Function 79. InStrRev( ) Function 80. StrComp( ) Function 81. Lcase( ) Function 82. Ucase( ) Function 83. Rnd( ) & Randomizer 84. Round( ) Function 85. VBScript Procedure 86. Ex.07 QTP Logon App.Script 87. Ex.08 Synchronization 88. Ex.09 Synchronization I/O 89. Ex.10 Output Parameter 90. Ex.11 Create Input Parameter 91. Check Points 92. Ex.12 Add Standard Checkpoint 93. Ex.13 Checking Objects 94. Ex.14 Page Checkpoint 95. Ex.15 Checking Text 96. Ex.16 Checking Tables 97. Ex.17 Parameterization Test 98. Testing Interview Part1 99. Testing Interview Part2 100.Testing Interview Part3 101.Testing Interview Part4 102.Testing Interview Part5 103.Testing Interview Part6 104.Testing Interview Part7 105.Testing Interview Part8 106.Testing Interview Part9 107.Testing Interview Part10 108.Testing Interview Part11
Pr.Pg Next Pg

Array Function tutorials

  • Go through the following program and you will notice that we have entered no for 5 times in variable name "No". This variable we have dealt so far can contain only single value and also known as Scalar Variable.

 

Program to VBScript to Give sum of numbers entered

Sam Sir

Rem VBScript Give sum of 5 numbers without ARRAY

Dim S,No,N

 

For N=1 TO 5

No=CInt(InputBox("Enter " & N & " Number ",0))

S=S+No

Next

MsgBox("Sum of 5 numbers = " & S)

MsgBox("Number Entered is " & No)

Output

If you execute above VBScript you will notice that it gives Sum of 5 Numbers according to numbers that are entered by you.

After coming out of loop, it display only Last Entered number.

There is no way in above program you can find numbers entered for 1 to 4th Loop. This is because Variable "No" can store only one value. While doing so it removes earlier value. So it will recall last value only.

 

  • An array is a contiguous area in the memory referred to by a common name. It is a series of variables having the same data type. Arrays are used to store related data values. VBScript allows you to store a group of common values together in the same location. These values can be accessed with their reference numbers. Array allow us to store a range of values in memory, each of which can be accessed quickly by referring to its position within Array.

 

Syntax

Dim Variable( No of Elements)

 

  • An array is made up of two parts, the array name and the no of element in array. The no indicates the highest index value for the elements within the array. Each element of an array has a unique identifying index number by which it can be referenced. VBScript creates zero based arrays where the first element of the array has an index value of zero.

 

For Eg.

Dim No(5)

Dim A = Array (20, 30, 40, 50)

 

  • This line of code creates an array, named No with 6 elements. Yes "SIX", cause VBScript arrays start with location 0. So Dim No(5) will create array having location range from No(0), No(1), No(2), No(3), No(4), No(5),In the next example it will create an array, named A with 4 elements.

  • After execution of Dim A = Array (20, 30, 40, 50) It will assign following values to

A(0) = 20

A(1) = 30

A(2) = 40

A(3) = 50

 

Program to VBScript to Give sum of numbers entered using Array

Sam Sir

Rem VBScript Give sum of 5 numbers with ARRAY

Dim S,N

Dim No(5)

 

For N=1 TO 5

No(N)=CInt(InputBox("Enter " & N & " Number ",0))

S=S+No(N)

Next

MsgBox("Sum of 5 numbers = " & S)

MsgBox("1st Number Entered is " & No(1))

MsgBox("1st Number Entered is " & No(2))

MsgBox("1st Number Entered is " & No(3))

MsgBox("1st Number Entered is " & No(4))

MsgBox("1st Number Entered is " & No(5))

Output

If you execute above VBScript you will notice that it gives Sum of 5 Numbers according to numbers that are entered by you.

After coming out of loop, it display All numbers that are entered by you.

So it will recall all values even out of loop using Array.

 

Pr.Pg border                                              Next Pg