File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -37,4 +37,10 @@ public static function getWordPressDir(): string
3737 }
3838 return self ::$ wordpress_dir ;
3939 }
40+
41+ public static function getLocalDeployDir (): string {
42+ $ dir = self ::getWordPressDir () . '/../localdeploy ' ;
43+ mkdir ( $ dir , 0775 , true );
44+ return realpath ( $ dir );
45+ }
4046}
Original file line number Diff line number Diff line change 77 */
88trait ITTrait {
99 public function setUp (): void {
10+ exec ( 'rm -rf ' . escapeshellarg ( ITEnv::getLocalDeployDir () ) );
1011 exec ( 'rm -rf ' . escapeshellarg ( ITEnv::getTestContentDir () ) );
1112
1213 $ this ->pluginCli ( [ 'delete_all_cache ' , '--force ' ] );
@@ -70,6 +71,13 @@ public function getCrawledFileContents( string $path ): string
7071 );
7172 }
7273
74+ public function getLocalDeployFileContents ( string $ path ): string {
75+ return $ this ->getFileContents (
76+ ITEnv::getLocalDeployDir (),
77+ $ path
78+ );
79+ }
80+
7381 public function getProcessedFileContents ( string $ path ): string
7482 {
7583 return $ this ->getFileContents (
You can’t perform that action at this time.
0 commit comments