24 lines
532 B
PHP
24 lines
532 B
PHP
<?php
|
|
|
|
namespace IQParts\ContentTest;
|
|
|
|
use PHPUnit\Framework\TestCase;
|
|
|
|
/**
|
|
* Class AbstractTestCase
|
|
* @package IQParts\ContentTest
|
|
*/
|
|
abstract class AbstractTestCase extends TestCase
|
|
{
|
|
public function getTmpDirectory()
|
|
{
|
|
$location = __DIR__ . '/../tmp';
|
|
if (!file_exists($location)) {
|
|
if (!mkdir($location)) {
|
|
throw new \RuntimeException('Could not create directory: ' . $location);
|
|
}
|
|
chmod($location, 0777);
|
|
}
|
|
return $location;
|
|
}
|
|
} |