FOSSology  4.4.0
Open Source License Compliance by Open Source Software
Fossology\Lib\Dao\UploadDaoTest Class Reference
Inheritance diagram for Fossology\Lib\Dao\UploadDaoTest:
Inheritance graph
Collaboration diagram for Fossology\Lib\Dao\UploadDaoTest:
Collaboration graph

Public Member Functions

 testGetNextItemWithEmptyArchive ()
 
 testGetPreviousItemWithEmptyArchive ()
 
 testGetNextItemWithSingleFile ()
 
 testGetPreviousItemWithSingleFile ()
 
 testGetNextItemWithNestedFile ()
 
 testGetPreviousItemWithNestedFile ()
 
 testGetNextItemWithFileAfterEmptyDirectory ()
 
 testGetPreviousItemWithFileAfterEmptyDirectory ()
 
 testGetNextItemWithMultipleFiles ()
 
 testGetPreviousItemWithMultipleFiles ()
 
 testGetNextItemUsesRecursiveAndRegularSearchAsFallback ()
 
 testGetPrevItemUsesRecursiveAndRegularSearchAsFallback ()
 
 testGetNextItemUsesRecursiveOnly ()
 
 testGetPrevItemUsesRecursiveOnly ()
 
 testGetNextFull ()
 
 testGetPreviousFull ()
 
 testCountNonArtifactDescendants ()
 
 testGetUploadParent ()
 
 testGetUploadParentFromBrokenTree ()
 
 testGetUploadParentFromNonExistingTree ()
 
 testGetUploadHashes ()
 
 testGetFatItem ()
 
 testGetAssigneeDate ()
 
 testGetClosedDate ()
 

Protected Member Functions

 setUp ()
 
 tearDown ()
 
 prepareUploadTree ($uploadTreeArray=array())
 
 prepareModularTable ($subentries=array())
 
 getSubentriesForSingleFile ()
 
 getSubentriesForNestedFile ()
 
 getSubentriesForFileAfterEmptyDirectory ()
 
 getSubentriesForMultipleFiles ()
 
 getTestFileStructure ()
 

Private Attributes

 $testDb
 
 $dbManager
 
 $uploadDao
 
 $entries
 

Detailed Description

Definition at line 20 of file UploadDaoTest.php.

Member Function Documentation

◆ getSubentriesForFileAfterEmptyDirectory()

Fossology\Lib\Dao\UploadDaoTest::getSubentriesForFileAfterEmptyDirectory ( )
protected
Returns
array

docs <-dir docs/txt <-dir README <-file

Definition at line 218 of file UploadDaoTest.php.

◆ getSubentriesForMultipleFiles()

Fossology\Lib\Dao\UploadDaoTest::getSubentriesForMultipleFiles ( )
protected
Returns
array

Definition at line 236 of file UploadDaoTest.php.

◆ getSubentriesForNestedFile()

Fossology\Lib\Dao\UploadDaoTest::getSubentriesForNestedFile ( )
protected
Returns
array

Definition at line 206 of file UploadDaoTest.php.

◆ getSubentriesForSingleFile()

Fossology\Lib\Dao\UploadDaoTest::getSubentriesForSingleFile ( )
protected
Returns
array

Definition at line 198 of file UploadDaoTest.php.

◆ prepareModularTable()

Fossology\Lib\Dao\UploadDaoTest::prepareModularTable (   $subentries = array())
protected
Parameters
$subentries

Definition at line 180 of file UploadDaoTest.php.

◆ prepareUploadTree()

Fossology\Lib\Dao\UploadDaoTest::prepareUploadTree (   $uploadTreeArray = array())
protected
Parameters
array$uploadTreeArray
Exceptions

Definition at line 167 of file UploadDaoTest.php.

◆ testGetAssigneeDate()

Fossology\Lib\Dao\UploadDaoTest::testGetAssigneeDate ( )
Test:

Test if getAssigneeDate() is giving assigning date, not closing date.

  1. Create an upload event with type ASSIGN_EVENT and one timestamp.
  2. Create another upload event with different type and different timestamp.
  3. Test if timestamp matches.
  4. Test if event does not exist, return value is null.

Definition at line 484 of file UploadDaoTest.php.

◆ testGetClosedDate()

Fossology\Lib\Dao\UploadDaoTest::testGetClosedDate ( )
Test:

Test if getClosedDate() is giving close date, not other date.

  1. Create an upload event with type UPLOAD_CLOSED_EVENT and one timestamp.
  2. Create another upload event with different type and different timestamp.
  3. Test if timestamp matches.
  4. Test if event does not exist, return value is null.

Definition at line 513 of file UploadDaoTest.php.

Member Data Documentation

◆ $entries

Fossology\Lib\Dao\UploadDaoTest::$entries
private
Initial value:
= array(
3653, 3668, 3683, 3685, 3671, 3665, 3676, 3675, 3681, 3677, 3673, 3658, 3660, 3686,
)

Filestructure ( NoLic files are removed) NR uploadtree_pk A 1 3653 B_NoLic C 2 3668 D D/E 3 3683 D/F_NoLic D/G 4 3685 H H/I_NoLic H/J 5 3671 H/K_NoLic L L/L1 L/L1/L1a_NoLic L/L2 L/L2/L2a 6 3665 L/L3 L/L3/L3a_NoLic M M/M1 N N/N1 7 3676 N/N2 N/N2/N2a_NoLic N/N3 8 3675 N/N4 N/N4/N4a 9 3681 N/N5 10 3677 O 11 3673 P P/P1_NoLic P/P2 P/P2/P2a 12 3658 P/P3 13 3660 R 14 3686

Definition at line 287 of file UploadDaoTest.php.


The documentation for this class was generated from the following file: