File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2121}
2222
2323if (strpos ($ options ['dsn ' ], 'sqlite::memory: ' ) === false ) {
24- Tester \Environment::lock ($ options ['dsn ' ], TEMP_DIR );
24+ Tester \Environment::lock ($ options ['dsn ' ], getTempDir () );
2525}
2626
2727$ driverName = $ connection ->getPdo ()->getAttribute (PDO ::ATTR_DRIVER_NAME );
Original file line number Diff line number Diff line change 1818}
1919
2020if (strpos ($ options ['dsn ' ], 'sqlite::memory: ' ) === false ) {
21- Tester \Environment::lock ($ options ['dsn ' ], TEMP_DIR );
21+ Tester \Environment::lock ($ options ['dsn ' ], getTempDir () );
2222}
2323
2424$ driverName = $ connection ->getPdo ()->getAttribute (PDO ::ATTR_DRIVER_NAME );
Original file line number Diff line number Diff line change 1616date_default_timezone_set ('Europe/Prague ' );
1717
1818
19- // create temporary directory
20- define ('TEMP_DIR ' , __DIR__ . '/tmp ' );
21- @mkdir (dirname (TEMP_DIR ));
22- @mkdir (TEMP_DIR );
19+ function getTempDir (): string
20+ {
21+ $ dir = __DIR__ . '/tmp ' ;
22+ @mkdir ($ dir );
23+ return $ dir ;
24+ }
2325
2426
2527function before (?Closure $ function = null )
You can’t perform that action at this time.
0 commit comments