@@ -1,6 +1,6 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | -declare(strict_types=1); |
|
| 3 | +declare(strict_types = 1); |
|
| 4 | 4 | |
| 5 | 5 | namespace Doctrine\Tests\ORM\Tools\Export; |
| 6 | 6 | |
@@ -65,7 +65,7 @@ discard block |
||
| 65 | 65 | 'xml' => XmlDriver::class, |
| 66 | 66 | ]; |
| 67 | 67 | |
| 68 | - self::assertArrayHasKey($type, $mappingDriver, "There is no metadata driver for the type '" . $type . "'."); |
|
| 68 | + self::assertArrayHasKey($type, $mappingDriver, "There is no metadata driver for the type '".$type."'."); |
|
| 69 | 69 | |
| 70 | 70 | $class = $mappingDriver[$type]; |
| 71 | 71 | $driver = ($type === 'annotation') |
@@ -88,10 +88,10 @@ discard block |
||
| 88 | 88 | |
| 89 | 89 | public function testExportDirectoryAndFilesAreCreated() |
| 90 | 90 | { |
| 91 | - $this->deleteDirectory(__DIR__ . '/export/'.$this->getType()); |
|
| 91 | + $this->deleteDirectory(__DIR__.'/export/'.$this->getType()); |
|
| 92 | 92 | |
| 93 | 93 | $type = $this->getType(); |
| 94 | - $metadataDriver = $this->createMetadataDriver($type, __DIR__ . '/' . $type); |
|
| 94 | + $metadataDriver = $this->createMetadataDriver($type, __DIR__.'/'.$type); |
|
| 95 | 95 | $em = $this->createEntityManager($metadataDriver); |
| 96 | 96 | $cmf = $this->createClassMetadataFactory($em, $type); |
| 97 | 97 | $metadata = $cmf->getAllMetadata(); |
@@ -103,7 +103,7 @@ discard block |
||
| 103 | 103 | |
| 104 | 104 | $type = $this->getType(); |
| 105 | 105 | $cme = new ClassMetadataExporter(); |
| 106 | - $exporter = $cme->getExporter($type, __DIR__ . '/export/' . $type); |
|
| 106 | + $exporter = $cme->getExporter($type, __DIR__.'/export/'.$type); |
|
| 107 | 107 | |
| 108 | 108 | if ($type === 'annotation') { |
| 109 | 109 | $exporter->setEntityGenerator(new EntityGenerator()); |
@@ -115,9 +115,9 @@ discard block |
||
| 115 | 115 | $exporter->export(); |
| 116 | 116 | |
| 117 | 117 | if ($type == 'annotation') { |
| 118 | - self::assertFileExists(__DIR__ . '/export/' . $type . '/'.str_replace('\\', '/', ExportedUser::class).$this->extension); |
|
| 118 | + self::assertFileExists(__DIR__.'/export/'.$type.'/'.str_replace('\\', '/', ExportedUser::class).$this->extension); |
|
| 119 | 119 | } else { |
| 120 | - self::assertFileExists(__DIR__ . '/export/' . $type . '/Doctrine.Tests.ORM.Tools.Export.ExportedUser'.$this->extension); |
|
| 120 | + self::assertFileExists(__DIR__.'/export/'.$type.'/Doctrine.Tests.ORM.Tools.Export.ExportedUser'.$this->extension); |
|
| 121 | 121 | } |
| 122 | 122 | } |
| 123 | 123 | |
@@ -128,7 +128,7 @@ discard block |
||
| 128 | 128 | { |
| 129 | 129 | $type = $this->getType(); |
| 130 | 130 | |
| 131 | - $metadataDriver = $this->createMetadataDriver($type, __DIR__ . '/export/' . $type); |
|
| 131 | + $metadataDriver = $this->createMetadataDriver($type, __DIR__.'/export/'.$type); |
|
| 132 | 132 | $em = $this->createEntityManager($metadataDriver); |
| 133 | 133 | $cmf = $this->createClassMetadataFactory($em, $type); |
| 134 | 134 | $metadata = $cmf->getAllMetadata(); |
@@ -381,7 +381,7 @@ discard block |
||
| 381 | 381 | $type = $this->getType(); |
| 382 | 382 | |
| 383 | 383 | if ($type === 'xml') { |
| 384 | - $xml = simplexml_load_file(__DIR__ . '/export/'.$type.'/Doctrine.Tests.ORM.Tools.Export.ExportedUser.dcm.xml'); |
|
| 384 | + $xml = simplexml_load_file(__DIR__.'/export/'.$type.'/Doctrine.Tests.ORM.Tools.Export.ExportedUser.dcm.xml'); |
|
| 385 | 385 | |
| 386 | 386 | $xml->registerXPathNamespace("d", "http://doctrine-project.org/schemas/orm/doctrine-mapping"); |
| 387 | 387 | $nodes = $xml->xpath("/d:doctrine-mapping/d:entity/d:one-to-many[@field='interests']/d:cascade/d:*"); |
@@ -405,10 +405,10 @@ discard block |
||
| 405 | 405 | if (is_file($path)) { |
| 406 | 406 | return unlink($path); |
| 407 | 407 | } else if (is_dir($path)) { |
| 408 | - $files = glob(rtrim($path,'/').'/*'); |
|
| 408 | + $files = glob(rtrim($path, '/').'/*'); |
|
| 409 | 409 | |
| 410 | 410 | if (is_array($files)) { |
| 411 | - foreach ($files as $file){ |
|
| 411 | + foreach ($files as $file) { |
|
| 412 | 412 | $this->deleteDirectory($file); |
| 413 | 413 | } |
| 414 | 414 | } |