@@ -106,17 +106,17 @@ discard block |
||
106 | 106 | $schemaAnalyzer = new SchemaAnalyzer($schemaManager); |
107 | 107 | $tdbmSchemaAnalyzer = new TDBMSchemaAnalyzer($this->tdbmService->getConnection(), new ArrayCache(), $schemaAnalyzer); |
108 | 108 | $this->tdbmDaoGenerator = new TDBMDaoGenerator($this->getConfiguration(), $tdbmSchemaAnalyzer); |
109 | - $this->rootPath = __DIR__ . '/../'; |
|
109 | + $this->rootPath = __DIR__.'/../'; |
|
110 | 110 | //$this->tdbmDaoGenerator->setComposerFile($this->rootPath.'composer.json'); |
111 | 111 | } |
112 | 112 | |
113 | 113 | public function testDaoGeneration(): void |
114 | 114 | { |
115 | 115 | // Remove all previously generated files. |
116 | - $this->recursiveDelete($this->rootPath . 'src/Test/Dao/'); |
|
117 | - mkdir($this->rootPath . 'src/Test/Dao/Generated', 0755, true); |
|
116 | + $this->recursiveDelete($this->rootPath.'src/Test/Dao/'); |
|
117 | + mkdir($this->rootPath.'src/Test/Dao/Generated', 0755, true); |
|
118 | 118 | // Let's generate a dummy file to see it is indeed removed. |
119 | - $dummyFile = $this->rootPath . 'src/Test/Dao/Generated/foobar.php'; |
|
119 | + $dummyFile = $this->rootPath.'src/Test/Dao/Generated/foobar.php'; |
|
120 | 120 | touch($dummyFile); |
121 | 121 | $this->assertFileExists($dummyFile); |
122 | 122 | |
@@ -126,7 +126,7 @@ discard block |
||
126 | 126 | |
127 | 127 | // Let's require all files to check they are valid PHP! |
128 | 128 | // Test the daoFactory |
129 | - require_once $this->rootPath . 'src/Test/Dao/Generated/DaoFactory.php'; |
|
129 | + require_once $this->rootPath.'src/Test/Dao/Generated/DaoFactory.php'; |
|
130 | 130 | // Test the others |
131 | 131 | |
132 | 132 | $beanDescriptors = $this->getDummyGeneratorListener()->getBeanDescriptors(); |
@@ -136,10 +136,10 @@ discard block |
||
136 | 136 | $daoBaseName = $beanDescriptor->getBaseDaoClassName(); |
137 | 137 | $beanName = $beanDescriptor->getBeanClassName(); |
138 | 138 | $baseBeanName = $beanDescriptor->getBaseBeanClassName(); |
139 | - require_once $this->rootPath . 'src/Test/Dao/Bean/Generated/' . $baseBeanName . '.php'; |
|
140 | - require_once $this->rootPath . 'src/Test/Dao/Bean/' . $beanName . '.php'; |
|
141 | - require_once $this->rootPath . 'src/Test/Dao/Generated/' . $daoBaseName . '.php'; |
|
142 | - require_once $this->rootPath . 'src/Test/Dao/' . $daoName . '.php'; |
|
139 | + require_once $this->rootPath.'src/Test/Dao/Bean/Generated/'.$baseBeanName.'.php'; |
|
140 | + require_once $this->rootPath.'src/Test/Dao/Bean/'.$beanName.'.php'; |
|
141 | + require_once $this->rootPath.'src/Test/Dao/Generated/'.$daoBaseName.'.php'; |
|
142 | + require_once $this->rootPath.'src/Test/Dao/'.$daoName.'.php'; |
|
143 | 143 | } |
144 | 144 | |
145 | 145 | // Check that pivot tables do not generate DAOs or beans. |
@@ -154,7 +154,7 @@ discard block |
||
154 | 154 | $schemaAnalyzer = new SchemaAnalyzer($schemaManager); |
155 | 155 | $tdbmSchemaAnalyzer = new TDBMSchemaAnalyzer($this->tdbmService->getConnection(), new ArrayCache(), $schemaAnalyzer); |
156 | 156 | $tdbmDaoGenerator = new TDBMDaoGenerator($configuration, $tdbmSchemaAnalyzer); |
157 | - $this->rootPath = __DIR__ . '/../../../../'; |
|
157 | + $this->rootPath = __DIR__.'/../../../../'; |
|
158 | 158 | //$tdbmDaoGenerator->setComposerFile($this->rootPath.'composer.json'); |
159 | 159 | |
160 | 160 | $this->expectException(NoPathFoundException::class); |
@@ -172,7 +172,7 @@ discard block |
||
172 | 172 | if (is_file($str)) { |
173 | 173 | return @unlink($str); |
174 | 174 | } elseif (is_dir($str)) { |
175 | - $scan = glob(rtrim($str, '/') . '/*'); |
|
175 | + $scan = glob(rtrim($str, '/').'/*'); |
|
176 | 176 | foreach ($scan as $index => $path) { |
177 | 177 | $this->recursiveDelete($path); |
178 | 178 | } |
@@ -1985,7 +1985,7 @@ discard block |
||
1985 | 1985 | { |
1986 | 1986 | $artists = new ArtistDao($this->tdbmService); |
1987 | 1987 | $pinkFloyd = $artists->getById(1); |
1988 | - $animals = $pinkFloyd->getAlbums()[0]; |
|
1988 | + $animals = $pinkFloyd->getAlbums()[0]; |
|
1989 | 1989 | $json = $pinkFloyd->jsonSerialize(); |
1990 | 1990 | // Collection name properly handled ('discography' instead of default 'albums') |
1991 | 1991 | self::assertTrue(isset($json['discography'])); |
@@ -2212,7 +2212,7 @@ discard block |
||
2212 | 2212 | |
2213 | 2213 | public function testMysqlStatementCount(): void |
2214 | 2214 | { |
2215 | - if (! $this->tdbmService->getConnection() instanceof MysqliConnection) { |
|
2215 | + if (!$this->tdbmService->getConnection() instanceof MysqliConnection) { |
|
2216 | 2216 | $this->markTestSkipped('This test only applies for MySQLi driver.'); |
2217 | 2217 | } |
2218 | 2218 | try { |