for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace PhpUnitGen\Model;
use PhpUnitGen\Model\ModelInterface\DirectoryModelInterface;
use PhpUnitGen\Model\ModelInterface\PhpFileModelInterface;
/**
* Class DirectoryModel.
*
* @author Paul Thébaud <[email protected]>.
* @copyright 2017-2018 Paul Thébaud <[email protected]>.
* @license https://opensource.org/licenses/MIT The MIT license.
* @link https://github.com/paul-thebaud/phpunit-generator
* @since Class available since Release 2.0.0.
*/
class DirectoryModel implements DirectoryModelInterface
{
* @var string $sourceDirectory The source directory (contains php files to parse).
private $sourceDirectory;
* @var string $targetDirectory The target directory (will contains generated tests files).
private $targetDirectory;
* @var PhpFileModel[] $phpFiles Php files contained in the directory (and sub directories).
private $phpFiles = [];
* {@inheritdoc}
public function setSourceDirectory(string $sourceDirectory): void
$this->sourceDirectory = $sourceDirectory;
}
public function getSourceDirectory(): string
return $this->sourceDirectory;
public function setTargetDirectory(string $targetDirectory): void
$this->targetDirectory = $targetDirectory;
public function getTargetDirectory(): string
return $this->targetDirectory;
public function addPhpFile(PhpFileModelInterface $phpFile): void
$this->phpFiles[] = $phpFile;
public function getPhpFiles(): array
return $this->phpFiles;