Files
luos/tests/automated/workflow/engine/classes/classarchiveTest.php
Marco Antonio Nina e2ef41981c phpunit classarchiveTest.php
- Initializing.
- Standard code.
2012-07-13 18:37:01 -04:00

225 lines
7.8 KiB
PHP

<?php
require_once PATH_TRUNK . 'gulliver/thirdparty/smarty/libs/Smarty.class.php';
require_once PATH_TRUNK . 'gulliver/system/class.xmlform.php';
require_once PATH_TRUNK . 'gulliver/system/class.xmlDocument.php';
require_once PATH_TRUNK . 'gulliver/system/class.form.php';
require_once PATH_TRUNK . 'gulliver/system/class.dbconnection.php';
require_once PATH_TRUNK . 'gulliver/thirdparty/propel/Propel.php';
require_once PATH_TRUNK . 'gulliver/thirdparty/creole/Creole.php';
require_once PATH_TRUNK . 'gulliver/thirdparty/pear/PEAR.php';
require_once PATH_TRUNK . 'workflow/engine/classes/class.archive.php';
/**
* Generated by ProcessMaker Test Unit Generator on 2012-07-12 at 22:32:30.
*/
class classarchiveTest extends PHPUnit_Framework_TestCase
{
/**
* @var archive
*/
protected $object;
/**
* Sets up the fixture, for example, opens a network connection.
* This method is called before a test is executed.
*/
protected function setUp()
{
$this->object = new archive('name');
}
/**
* Tears down the fixture, for example, closes a network connection.
* This method is called after a test is executed.
*/
protected function tearDown()
{
}
/**
* This is the default method to test, if the class still having
* the same number of methods.
*/
public function testNumberOfMethodsInThisClass()
{
$methods = get_class_methods('archive');
$this->assertTrue( count($methods) == 12);
}
/**
* @covers archive::archive
* @todo Implement testarchive().
*/
public function testarchive()
{
$methods = get_class_methods($this->object);
$this->assertTrue( in_array('archive', $methods ), 'exists method archive' );
$r = new ReflectionMethod('archive', 'archive');
$params = $r->getParameters();
$this->assertTrue( $params[0]->getName() == 'name');
$this->assertTrue( $params[0]->isArray() == false);
$this->assertTrue( $params[0]->isOptional () == false);
}
/**
* @covers archive::set_options
* @todo Implement testset_options().
*/
public function testset_options()
{
$methods = get_class_methods($this->object);
$this->assertTrue( in_array('set_options', $methods ), 'exists method set_options' );
$r = new ReflectionMethod('archive', 'set_options');
$params = $r->getParameters();
$this->assertTrue( $params[0]->getName() == 'options');
$this->assertTrue( $params[0]->isArray() == false);
$this->assertTrue( $params[0]->isOptional () == false);
}
/**
* @covers archive::create_archive
* @todo Implement testcreate_archive().
*/
public function testcreate_archive()
{
$methods = get_class_methods($this->object);
$this->assertTrue( in_array('create_archive', $methods ), 'exists method create_archive' );
$r = new ReflectionMethod('archive', 'create_archive');
$params = $r->getParameters();
}
/**
* @covers archive::add_data
* @todo Implement testadd_data().
*/
public function testadd_data()
{
$methods = get_class_methods($this->object);
$this->assertTrue( in_array('add_data', $methods ), 'exists method add_data' );
$r = new ReflectionMethod('archive', 'add_data');
$params = $r->getParameters();
$this->assertTrue( $params[0]->getName() == 'data');
$this->assertTrue( $params[0]->isArray() == false);
$this->assertTrue( $params[0]->isOptional () == false);
}
/**
* @covers archive::make_list
* @todo Implement testmake_list().
*/
public function testmake_list()
{
$methods = get_class_methods($this->object);
$this->assertTrue( in_array('make_list', $methods ), 'exists method make_list' );
$r = new ReflectionMethod('archive', 'make_list');
$params = $r->getParameters();
}
/**
* @covers archive::add_files
* @todo Implement testadd_files().
*/
public function testadd_files()
{
$methods = get_class_methods($this->object);
$this->assertTrue( in_array('add_files', $methods ), 'exists method add_files' );
$r = new ReflectionMethod('archive', 'add_files');
$params = $r->getParameters();
$this->assertTrue( $params[0]->getName() == 'list');
$this->assertTrue( $params[0]->isArray() == false);
$this->assertTrue( $params[0]->isOptional () == false);
}
/**
* @covers archive::exclude_files
* @todo Implement testexclude_files().
*/
public function testexclude_files()
{
$methods = get_class_methods($this->object);
$this->assertTrue( in_array('exclude_files', $methods ), 'exists method exclude_files' );
$r = new ReflectionMethod('archive', 'exclude_files');
$params = $r->getParameters();
$this->assertTrue( $params[0]->getName() == 'list');
$this->assertTrue( $params[0]->isArray() == false);
$this->assertTrue( $params[0]->isOptional () == false);
}
/**
* @covers archive::store_files
* @todo Implement teststore_files().
*/
public function teststore_files()
{
$methods = get_class_methods($this->object);
$this->assertTrue( in_array('store_files', $methods ), 'exists method store_files' );
$r = new ReflectionMethod('archive', 'store_files');
$params = $r->getParameters();
$this->assertTrue( $params[0]->getName() == 'list');
$this->assertTrue( $params[0]->isArray() == false);
$this->assertTrue( $params[0]->isOptional () == false);
}
/**
* @covers archive::list_files
* @todo Implement testlist_files().
*/
public function testlist_files()
{
$methods = get_class_methods($this->object);
$this->assertTrue( in_array('list_files', $methods ), 'exists method list_files' );
$r = new ReflectionMethod('archive', 'list_files');
$params = $r->getParameters();
$this->assertTrue( $params[0]->getName() == 'list');
$this->assertTrue( $params[0]->isArray() == false);
$this->assertTrue( $params[0]->isOptional () == false);
}
/**
* @covers archive::parse_dir
* @todo Implement testparse_dir().
*/
public function testparse_dir()
{
$methods = get_class_methods($this->object);
$this->assertTrue( in_array('parse_dir', $methods ), 'exists method parse_dir' );
$r = new ReflectionMethod('archive', 'parse_dir');
$params = $r->getParameters();
$this->assertTrue( $params[0]->getName() == 'dirname');
$this->assertTrue( $params[0]->isArray() == false);
$this->assertTrue( $params[0]->isOptional () == false);
}
/**
* @covers archive::sort_files
* @todo Implement testsort_files().
*/
public function testsort_files()
{
$methods = get_class_methods($this->object);
$this->assertTrue( in_array('sort_files', $methods ), 'exists method sort_files' );
$r = new ReflectionMethod('archive', 'sort_files');
$params = $r->getParameters();
$this->assertTrue( $params[0]->getName() == 'a');
$this->assertTrue( $params[0]->isArray() == false);
$this->assertTrue( $params[0]->isOptional () == false);
$this->assertTrue( $params[1]->getName() == 'b');
$this->assertTrue( $params[1]->isArray() == false);
$this->assertTrue( $params[1]->isOptional () == false);
}
/**
* @covers archive::download_file
* @todo Implement testdownload_file().
*/
public function testdownload_file()
{
$methods = get_class_methods($this->object);
$this->assertTrue( in_array('download_file', $methods ), 'exists method download_file' );
$r = new ReflectionMethod('archive', 'download_file');
$params = $r->getParameters();
}
}