FOSSology  3.2.0rc1
Open Source License Compliance by Open Source Software
test_Traverse.c File Reference

Unit test cases for Traverse() More...

#include "run_tests.h"
Include dependency graph for test_Traverse.c:

Go to the source code of this file.

Functions

int TraverseInit ()
 initialize
 
int TraverseClean ()
 clean env and others
 
void testTraverseNormal4Package ()
 normal test for one package More...
 
void testTraverseNormal4Package2 ()
 normal test for one package another case More...
 
void testTraverseNormal4Dir ()
 normal test for one directory More...
 
void testTraverseNormal4Rpm ()
 normal test for rpm More...
 
void testTraverseNullParams ()
 abnormal test for null parameters More...
 

Variables

static char * Label = "called by main"
 
static char * Basename =""
 
static ParentInfoPI = NULL
 
static int Result = 0
 
CU_TestInfo Traverse_testcases []
 Traverse() test cases. More...
 

Detailed Description

Unit test cases for Traverse()

Definition in file test_Traverse.c.

Function Documentation

void testTraverseNormal4Dir ( )

normal test for one directory

Test:
  1. Call Traverse() on a directory containing packages
  2. Check if the files are unpacked properly

Definition at line 96 of file test_Traverse.c.

void testTraverseNormal4Package ( )

normal test for one package

Test:
  1. Call Traverse() on a single package
  2. Check if the files are unpacked

Definition at line 58 of file test_Traverse.c.

void testTraverseNormal4Package2 ( )

normal test for one package another case

Test:
  1. Call Traverse() on a single package
  2. Check if the files are unpacked

Definition at line 77 of file test_Traverse.c.

void testTraverseNormal4Rpm ( )

normal test for rpm

Test:
  1. Call Traverse() on a single RPM package
  2. Check if the files are unpacked

Definition at line 123 of file test_Traverse.c.

void testTraverseNullParams ( )

abnormal test for null parameters

Test:
  1. Call Traverse() on empty strings
  2. Check if function returns 0
  3. Check if nothing is done by function

Definition at line 143 of file test_Traverse.c.

Variable Documentation

CU_TestInfo Traverse_testcases[]
Initial value:
=
{
{"Traverse normal package:", testTraverseNormal4Package},
{"Traverse normal package another:", testTraverseNormal4Package2},
{"Traverse normal directory:", testTraverseNormal4Dir},
{"Traverse normal rpm:", testTraverseNormal4Rpm},
{"Traverse null paramters:", testTraverseNullParams},
CU_TEST_INFO_NULL
}
void testTraverseNormal4Rpm()
normal test for rpm
void testTraverseNormal4Package()
normal test for one package
Definition: test_Traverse.c:58
void testTraverseNullParams()
abnormal test for null parameters
void testTraverseNormal4Dir()
normal test for one directory
Definition: test_Traverse.c:96
void testTraverseNormal4Package2()
normal test for one package another case
Definition: test_Traverse.c:77

Traverse() test cases.

Definition at line 160 of file test_Traverse.c.