diff -r bbdc7f9aa25e -r 03b14b0fe101 vendor/doctrine-migrations/tests/Doctrine/DBAL/Migrations/Tests/VersionTest.php --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/vendor/doctrine-migrations/tests/Doctrine/DBAL/Migrations/Tests/VersionTest.php Fri Nov 25 18:55:43 2011 +0100 @@ -0,0 +1,58 @@ +getSqliteConnection()), $versionName = '003', + 'Doctrine\DBAL\Migrations\Tests\VersionTest_Migration'); + $this->assertEquals($versionName, $version->getVersion()); + } + + /** + * Create migration with custom name + */ + public function testCreateVersionWithCustomName() + { + $versionName = 'CustomVersionName'; + $version = new Version(new Configuration($this->getSqliteConnection()), '003', + 'Doctrine\DBAL\Migrations\Tests\VersionTest_MigrationCustom'); + $this->assertEquals($versionName, $version->getVersion()); + } +} + +/** + * Simple migration + */ +class VersionTest_Migration extends AbstractMigration +{ + public function down(Schema $schema) {} + public function up(Schema $schema) {} +} + +/** + * Migration with custom name + */ +class VersionTest_MigrationCustom extends AbstractMigration +{ + public function getName() + { + return 'CustomVersionName'; + } + public function down(Schema $schema) {} + public function up(Schema $schema) {} +} \ No newline at end of file