mirror of
				https://github.com/hauke68/Magallanes.git
				synced 2025-11-04 00:50:18 +01:00 
			
		
		
		
	Merge pull request #175 from claudioflagbit/version-command-test
Test added for VersionCommand
This commit is contained in:
		
						commit
						55aaa5c3b4
					
				@ -15,5 +15,9 @@
 | 
			
		||||
        <directory suffix=".php">src</directory>
 | 
			
		||||
      </whitelist>
 | 
			
		||||
    </filter>
 | 
			
		||||
 | 
			
		||||
    <php>
 | 
			
		||||
        <const name="MAGALLANES_VERSION" value="2" />
 | 
			
		||||
    </php>
 | 
			
		||||
</phpunit>
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
							
								
								
									
										30
									
								
								tests/MageTest/Command/BuiltIn/VersionCommandTest.php
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										30
									
								
								tests/MageTest/Command/BuiltIn/VersionCommandTest.php
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,30 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace MageTest\Command\BuiltIn;
 | 
			
		||||
 | 
			
		||||
use Mage\Command\BuiltIn\VersionCommand;
 | 
			
		||||
use Mage\Console;
 | 
			
		||||
use MageTest\TestHelper\BaseTest;
 | 
			
		||||
use PHPUnit_Framework_TestCase;
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * @coversDefaultClass Mage\Command\BuiltIn\VersionCommands
 | 
			
		||||
 * @group Mage_Command_BuildIn_VersionCommand
 | 
			
		||||
 * @uses Mage\Console
 | 
			
		||||
 * @uses Mage\Console\Colors
 | 
			
		||||
 */
 | 
			
		||||
class VersionCommandTest extends BaseTest
 | 
			
		||||
{
 | 
			
		||||
    /**
 | 
			
		||||
     * @group 175
 | 
			
		||||
     * @covers Mage\Command\BuiltIn\VersionCommand::run()
 | 
			
		||||
     */
 | 
			
		||||
    public function testRun()
 | 
			
		||||
    {
 | 
			
		||||
        $this->setUpConsoleStatics();
 | 
			
		||||
        $command = new VersionCommand();
 | 
			
		||||
        $command->run();
 | 
			
		||||
 | 
			
		||||
        $this->expectOutputString('Running Magallanes version 2' . str_repeat(PHP_EOL, 2));
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
		Loading…
	
		Reference in New Issue
	
	Block a user