2010-06-20 02:28:20 +04:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace Doctrine\Tests\ORM\Tools\Console\Command;
|
|
|
|
|
|
|
|
use Doctrine\ORM\Tools\Console\Command\ConvertDoctrine1SchemaCommand;
|
|
|
|
|
|
|
|
class ConvertDoctrine1SchemaCommandTest extends \Doctrine\Tests\OrmTestCase
|
|
|
|
{
|
|
|
|
public function testExecution()
|
|
|
|
{
|
|
|
|
$entityGenerator = $this->getMock('Doctrine\ORM\Tools\EntityGenerator');
|
|
|
|
$command = new ConvertDoctrine1SchemaCommand();
|
|
|
|
$command->setEntityGenerator($entityGenerator);
|
|
|
|
|
2010-08-23 21:44:15 +04:00
|
|
|
$output = $this->getMock('Symfony\Component\Console\Output\OutputInterface');
|
2010-06-20 02:28:20 +04:00
|
|
|
$output->expects($this->once())
|
2012-11-03 20:07:56 +04:00
|
|
|
->method('writeln')
|
|
|
|
->with($this->equalTo('No Metadata Classes to process.'));
|
2010-06-20 02:28:20 +04:00
|
|
|
|
2012-11-03 20:07:56 +04:00
|
|
|
$command->convertDoctrine1Schema(array(), sys_get_temp_dir(), 'annotation', 4, null, $output);
|
2010-06-20 02:28:20 +04:00
|
|
|
}
|
2012-11-03 20:07:56 +04:00
|
|
|
}
|