Challenge

Project 2 - V&V SW Analysis II

  1. Q.Perform Integration testing by including all the .C files available in the folder location C:\**\LDRA_workarea\Examples\Toolsuite\Cashregister_6.0\ **

A)Create the test cases manually as well as automatically using TBExtreme and upload the reports.

B)store the test cases as .tcf file. Upload the location image where the .tcf file is stored.

LDRA tool suite EE Test Case Pass Fail Report and .tcf also uploaded

Integration testing (sometimes called integration and testing, abbreviated I&T) is the phase in software testing in which individual software modules are combined and tested as a group

Procedure

  • Integration testing is performed foe all .c files in the Cashregister_6.0
  • Select source , select multiple file create a file add the required .c files for testing and create file
  • Cashregister.c,userinterface.c and main.c are chosen for testing
  • Stub management is done by creating sequence
  • Static code analysis id done and result is obtained from test manager report
  • White box testing is done for multiple files
  • Testing is done by selecting run extreme tabular test
  • Regression report, Dynamic coverage test report is analyzed

Figure 1 shows running staic analysis(Test Build program was build successfully)

add product: test case passed

add product function test case

  1. Perform Static Code Review Analysis for “C:\**\LDRA_workarea\Examples\C_Testbed_examples\Testrain\Testrain.c” Generate Code review report and upload them.

unable to take the screen short

/* TESTRIAN - an ANSI C triangle example */
#include <stdio.h>

void equalsides(int i,int j,int k,int *match)
{
*match = 0;
if( i==j) ++ *match;
if( i==k) {++ *match;++ *match;};
if( k==j) {++ *match;++ *match;++ *match;};
}

void printtype(int i,int j,int k,int match)
{
if( match == 0 ) goto l1;
else
if( match == 1 ) goto l2;
else
if( match == 2 ) goto l3;
else
if( match == 3 ) goto l4;
goto equil;
l1: if(i+j<=k) goto not_a_tri;
if(j+k<=i) goto not_a_tri;
if(i+k<=j) goto not_a_tri; else goto scalene;
l2: if(i+j<=k ) goto l1; else goto isos;
l3: if(i+k<=j ) goto not_a_tri; else goto isos;
l4: if(j+k<=i ) goto not_a_tri;else goto isos;
equil: printf(" equilateral");
goto end;
isos: printf(" isosceles");

goto end;
not_a_tri: printf(" not a triangle");
goto end;
scalene: printf(" scalene");
end:;
}

/* Data flow Anomalies */

void datanoma(int z)
{
int w,x,y;
w=5;
if (z == 0) goto l5;
z=0;
z=y;
z=2;
l5: z=3;
z=4;
goto l6;
z=5;
z=6;
z=7;
z=8;
z=9;
l6: z=10;
}


void knots()
{
int u,v;

/* down-down knot */
if (u==1) goto lb;
la: v=0;
v=0;
v=0;
if (u==2) goto lc;
lb: v=0;
v=0;
v=0;
lc: v=0;

/* up-down knot */
ld: v=0;
v=0;
v=0;
if (u==3) goto ld;
v=0;
v=0;

/* up-up knot */
le: v=0;
v=0;
lf: v=0;
v=0;
if (u==4) goto le;
v=0;
v=0;
if (u==3) goto lf;
v=0;
}

int main()
{ int i,j,k,n,match;
printf("\n input number of triangles \n");
scanf("%d",&n);
while (n>0)
{ n--;
printf("\n input 3 integers \n");
scanf("%d %d %d", &i,&j,&k);
/*LDRA_assert*/
/*
i>0 && j> 0 && k>0
*/
/*LDRA_end*/
if(n==4) datanoma(0);
if(n==999) knots();
equalsides(i,j,k,&match);
printtype(i,j,k,match);
}
return 0;
}

Your portfolio, next

Ship work like this
in your own course.

Talk to a career counsellor

Free 20-minute call. We'll map the right course to where you want to work.

By submitting you agree to our Terms and Privacy Policy.