Skip to content

Commit

Permalink
refactor(WPBrowser) clean Symlinker setup output
Browse files Browse the repository at this point in the history
  • Loading branch information
lucatume committed Jun 25, 2024
1 parent 8d7bbe9 commit 8e8e212
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 27 deletions.
10 changes: 3 additions & 7 deletions src/Project/ContentProject.php
Original file line number Diff line number Diff line change
Expand Up @@ -115,16 +115,12 @@ public function setup(): void
EOT;

$symlinkerConfig = [
'wpRootFolder' => '%WORDPRESS_ROOT_DIR%',
'plugins' => [],
'themes' => []
];
$symlinkerConfig = [ 'wpRootFolder' => '%WORDPRESS_ROOT_DIR%' ];

if ($this instanceof PluginProject) {
$symlinkerConfig['plugins'][] = '.';
$symlinkerConfig['plugins'] = ['.'];
} elseif ($this instanceof ThemeProject) {
$symlinkerConfig['themes'][] = '.';
$symlinkerConfig['themes'] = ['.'];
}

$this->testEnvironment->extensionsEnabled = [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -272,8 +272,8 @@ TEST_TABLE_PREFIX=test_
WORDPRESS_TABLE_PREFIX=wp_

# The URL and domain of the WordPress site used in end-to-end tests.
WORDPRESS_URL=http://localhost:47453
WORDPRESS_DOMAIN=localhost:47453
WORDPRESS_URL=http://localhost:8970
WORDPRESS_DOMAIN=localhost:8970
WORDPRESS_ADMIN_PATH=/wp-admin

# The username and password of the administrator user of the WordPress site used in end-to-end tests.
Expand All @@ -282,10 +282,10 @@ WORDPRESS_ADMIN_PASSWORD=password

# The host and port of the ChromeDriver server that will be used in end-to-end tests.
CHROMEDRIVER_HOST=localhost
CHROMEDRIVER_PORT=43984
CHROMEDRIVER_PORT=43956

# The port on which the PHP built-in server will serve the WordPress installation.
BUILTIN_SERVER_PORT=47453
BUILTIN_SERVER_PORT=8970

<<< /tests/.env <<<

Expand Down Expand Up @@ -327,7 +327,6 @@ extensions:
DB_FILE: db.sqlite
lucatume\WPBrowser\Extension\Symlinker:
wpRootFolder: '%WORDPRESS_ROOT_DIR%'
plugins: { }
themes:
- .
commands:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -267,8 +267,8 @@ TEST_TABLE_PREFIX=test_
WORDPRESS_TABLE_PREFIX=wp_

# The URL and domain of the WordPress site used in end-to-end tests.
WORDPRESS_URL=http://localhost:42934
WORDPRESS_DOMAIN=localhost:42934
WORDPRESS_URL=http://localhost:27090
WORDPRESS_DOMAIN=localhost:27090
WORDPRESS_ADMIN_PATH=/wp-admin

# The username and password of the administrator user of the WordPress site used in end-to-end tests.
Expand All @@ -277,10 +277,10 @@ WORDPRESS_ADMIN_PASSWORD=password

# The host and port of the ChromeDriver server that will be used in end-to-end tests.
CHROMEDRIVER_HOST=localhost
CHROMEDRIVER_PORT=44670
CHROMEDRIVER_PORT=55678

# The port on which the PHP built-in server will serve the WordPress installation.
BUILTIN_SERVER_PORT=42934
BUILTIN_SERVER_PORT=27090

<<< /tests/.env <<<

Expand Down Expand Up @@ -324,7 +324,6 @@ extensions:
wpRootFolder: '%WORDPRESS_ROOT_DIR%'
plugins:
- .
themes: { }
commands:
- lucatume\WPBrowser\Command\RunOriginal
- lucatume\WPBrowser\Command\RunAll
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -272,8 +272,8 @@ TEST_TABLE_PREFIX=test_
WORDPRESS_TABLE_PREFIX=wp_

# The URL and domain of the WordPress site used in end-to-end tests.
WORDPRESS_URL=http://localhost:16769
WORDPRESS_DOMAIN=localhost:16769
WORDPRESS_URL=http://localhost:45130
WORDPRESS_DOMAIN=localhost:45130
WORDPRESS_ADMIN_PATH=/wp-admin

# The username and password of the administrator user of the WordPress site used in end-to-end tests.
Expand All @@ -282,10 +282,10 @@ WORDPRESS_ADMIN_PASSWORD=password

# The host and port of the ChromeDriver server that will be used in end-to-end tests.
CHROMEDRIVER_HOST=localhost
CHROMEDRIVER_PORT=20529
CHROMEDRIVER_PORT=53682

# The port on which the PHP built-in server will serve the WordPress installation.
BUILTIN_SERVER_PORT=16769
BUILTIN_SERVER_PORT=45130

<<< /tests/.env <<<

Expand Down Expand Up @@ -329,7 +329,6 @@ extensions:
wpRootFolder: '%WORDPRESS_ROOT_DIR%'
plugins:
- .
themes: { }
commands:
- lucatume\WPBrowser\Command\RunOriginal
- lucatume\WPBrowser\Command\RunAll
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -272,8 +272,8 @@ TEST_TABLE_PREFIX=test_
WORDPRESS_TABLE_PREFIX=wp_

# The URL and domain of the WordPress site used in end-to-end tests.
WORDPRESS_URL=http://localhost:8847
WORDPRESS_DOMAIN=localhost:8847
WORDPRESS_URL=http://localhost:32075
WORDPRESS_DOMAIN=localhost:32075
WORDPRESS_ADMIN_PATH=/wp-admin

# The username and password of the administrator user of the WordPress site used in end-to-end tests.
Expand All @@ -282,10 +282,10 @@ WORDPRESS_ADMIN_PASSWORD=password

# The host and port of the ChromeDriver server that will be used in end-to-end tests.
CHROMEDRIVER_HOST=localhost
CHROMEDRIVER_PORT=7561
CHROMEDRIVER_PORT=26026

# The port on which the PHP built-in server will serve the WordPress installation.
BUILTIN_SERVER_PORT=8847
BUILTIN_SERVER_PORT=32075

<<< /tests/.env <<<

Expand Down Expand Up @@ -327,7 +327,6 @@ extensions:
DB_FILE: db.sqlite
lucatume\WPBrowser\Extension\Symlinker:
wpRootFolder: '%WORDPRESS_ROOT_DIR%'
plugins: { }
themes:
- .
commands:
Expand Down

0 comments on commit 8e8e212

Please sign in to comment.