Project 2 - V&V SW Analysis II
step by step procedure for 1st question
Since LDRA tool is not working procedure is written step by step
Unit testing in manually
Test mode: Block box mode
Steps involved
Step 1: Select the source file to be tested
After selection, all necessary analysis will be done by the LDRA tool before applying test cases
Step 2: Create new sequence (To perform test case)
Step 3: Select the testing mode should be done (black box mode or white box mode)
Step 4: Create new test case on the function to which test case should to be applied
Step 5: Select any of the following to perform test cases on the function
1) standard-single test case
2) repetition
3) iteration
4) ranged
Step 6: Give inputs in variable I/O view window and, we can give expected output in the same window
Step 7: we should generate driver code (Run driver-> generate driver code)
Step 8: we should build this code (Run driver-> build this code)
Step 9: we should execute this driver code (Run driver-> execute this driver code)
Step 10: we should process driver code (Run driver-> process driver code)
Instead of using step by step process we can use Run driver
So that test case results will be appear in the window
Step11: From results select regression analysis
Results -> regression analysis report
since we are doing in black box mode, we can see only regression analysis.
In regression report we can see outputs for corresponding inputs given in the test cases
Test mode: white box mode
Step 1: Now change the test mode into white box mode
Step 2: Repeat the same process from step 4 to step 10
Step 3: or select Run driver
Step 4: So that test results will be generated
Step 5: Select Results->dynamic coverage analysis
so that we can get branch coverage analysis
Step 6: If branch coverage analysis is less than 100%, create another test case with necessary inputs and perform step3 to make branch coverage analysis to 100%
pass/fail flow diagram- It is graphical way of representation, in which we can see the flow chart of the pass/fail test case branches
Step 7: This branch coverage analysis can be seen in dynamic coverage analysis report
Results -> regression dynamic coverage analysis report
To store test cases
test case->store new test case
to export test cases
sequence->export test cases
to import test cases
create new sequence->test cases->import test cases->select the .tcf file
If pointer variable is there in the code
If we are using pointers, we should make use of global variable
create test case->assign input pointer in i/o view
Unit testing in automatically
Step 1: create new sequence
Step 2: select run tabular extreme test for each function
Step 3: run test cases
To control number of test cases following option is selected
Extreme test-> run tabular extreme test cases
Here we can control number of test cases by selecting configuration options like
unresolved symbol options,
execution options,
test scope options,
IO value options
Step 4: to see test results
Results-> dynamic coverage analysis report
Results-> regression analysis report
Step by step procedure for 2nd question
Since LDRA tool is not working procedure is written step by step
Unit testing in Manually
Test mode: Block box mode
Steps involved
Step 1: Select the source file
After selection all necessary analysis will be done before applying test cases
Step 2: Stub management->create managed stubs for sequence
All unresolved functions will be stubbed
Step 3:by running test build option we can see any unresolved functions
If any such function are repeat step 2
Step 4: If any global variables are declared we can resolve this variable using the following instruction
Global variables->automatically declare unresolved variables
Step 5: Create new sequence (To perform test case)
Step 6: select the test cases should be done on black box mode
Step 7: Create new test case on the function to which test case should to be applied
Step 8: select any of the following
1) standard-single test case
2) repetition
3) iteration
4) ranged
Step 9: since we are using structure pointer in the program, we must specify the value to the structure and we must specify the number of elements to be considered
Step 6: Give inputs in variable I/O view and, we can give expected output in the same window
Step 7: we should generate driver code
Step 8: we should build this code
Step 9: we should execute this driver code
Step 10: we should process driver code
Instead of using step by step process we can use Run driver
So that test case results will be appear in the window
Step11: From results select regression analysis
since we are doing in black box mode, we can see only regression analysis
Test mode: white box mode
Step 1: now change the test into white box mode
Step 2: repeat the same process from step 4 to step 10 or select run driver
so that we can get branch coverage analysis
Step 3: So that test results will be generated
Step 4: Select Results->dynamic coverage analysis
so that we can get branch coverage analysis
Step 5: If branch coverage analysis is less than 100%, create another test case with necessary inputs and perform step 2 to make branch coverage analysis to 100%
pass/fail flow diagram- It is graphical way of representation, in which we can see the flow chart of the pass/fail test case branches
Step 6: This branch coverage analysis can be seen in dynamic coverage analysis report
Results -> regression dynamic coverage analysis report
to store test cases
test case->store new test case
to export test cases
sequence->export test cases
to import test cases
create new sequence->test cases->import test cases->select the .tcf file
Pointers
if we are using pointers, we should make use of global variable
create test case->assign input pointer in i/o view
File call diagram
open file call diagram- so that we see graphical view of the file dependents
stub management-> create managed stubs for sequence
to overcome linker variable problem, we should use global variable->automatically declare unresolved global
Unit testing in automatically
Step 1: create new sequence
Step 2: select run tabular extreme test for each function
Step 3: run test cases
To control number of test cases following option is selected
Extreme test-> run tabular extreme test cases
Here we can control number of test cases by selecting configuration options like
unresolved symbol options,
execution options,
test scope options,
IO value options
Step 4: to see test results
Results-> dynamic coverage analysis report
Results-> regression analysis report