Skip to content

Commit

Permalink
Merge pull request #7 from stellarwp/chore/update-github-actions-vers…
Browse files Browse the repository at this point in the history
…ions

Update GitHub actions versions + Codeception/WP Browser fixes
  • Loading branch information
defunctl authored Mar 18, 2024
2 parents 7594f93 + fa99ae2 commit 391a805
Show file tree
Hide file tree
Showing 7 changed files with 20 additions and 17 deletions.
22 changes: 11 additions & 11 deletions .env.testing
Original file line number Diff line number Diff line change
Expand Up @@ -7,39 +7,39 @@ WP_VERSION=latest

# This is where, in the context of the CI, we'll install and configure WordPress.
# See `.travis.yml` for more information.
WP_ROOT_FOLDER=/tmp/wordpress
WP_ROOT_FOLDER=/var/www/html

# The WordPress installation will be served from the Docker container.
# See `dev/docker/ci-compose.yml` for more information.
WP_URL=http://localhost:8080
WP_DOMAIN=localhost:8080
WP_URL=http://wordpress.test
WP_DOMAIN=wordpress.test

# The credentials that will be used to access the site in acceptance tests
# in methods like `$I->loginAsAdmin();`.
WP_ADMIN_USERNAME=admin
WP_ADMIN_PASSWORD=password

WP_DB_PORT=4306
WP_DB_PORT=3306

# The databse is served from the Docker `db` container.
# See `dev/docker/ci-compose.yml` for more information.
WP_TABLE_PREFIX=wp_
WP_DB_HOST=127.0.0.1:4306
WP_DB_NAME=wordpress
WP_DB_HOST=db
WP_DB_NAME=test
WP_DB_USER=root
WP_DB_PASSWORD=
WP_DB_PASSWORD=password

# The test databse is served from the Docker `db` container.
# See `dev/docker/ci-compose.yml` for more information.
WP_TEST_DB_HOST=127.0.0.1:4306
WP_TEST_DB_HOST=db
WP_TEST_DB_NAME=test
WP_TEST_DB_USER=root
WP_TEST_DB_PASSWORD=
WP_TEST_DB_PASSWORD=password

# We're using Selenium and Chrome for acceptance testing.
# In CI context we're starting a Docker container to handle that.
# See the `dev/docker/ci-compose.yml` file.
CHROMEDRIVER_HOST=localhost
CHROMEDRIVER_HOST=chrome
CHROMEDRIVER_PORT=4444

# The URL of the WordPress installation from the point of view of the Chromedriver container.
Expand All @@ -48,7 +48,7 @@ CHROMEDRIVER_PORT=4444
# lines that, in the `wp-config.php` file, will make it so that WordPress will use as its home
# URL whatever URL we reach it with.
# See the `dev/docker/wp-config.php` template for more information.
WP_CHROMEDRIVER_URL="wp.test"
WP_CHROMEDRIVER_URL=http://wordpress.test

# To run the tests let's force the background-processing lib to run in synchronous (single PHP thread) mode.
TRIBE_NO_ASYNC=1
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/coding-standards.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,14 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v4

- name: Configure PHP environment
uses: shivammathur/setup-php@v2
with:
php-version: '8.0'

- uses: ramsey/composer-install@v2
- uses: ramsey/composer-install@v3
with:
composer-options: "--ignore-platform-reqs --optimize-autoloader"

Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/static-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v4
- name: Configure PHP environment
uses: shivammathur/setup-php@v2
with:
php-version: '8.0'
extensions: mbstring, intl
coverage: none
- uses: ramsey/composer-install@v2
- uses: ramsey/composer-install@v3
with:
composer-options: "--ignore-platform-reqs --optimize-autoloader"
- name: Run PHPStan static analysis
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/tests-php.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
name: "Tests: WP ${{ matrix.wordpress }} / PHP ${{ matrix.php }}"
steps:
- name: Checkout the repository
uses: actions/checkout@v2
uses: actions/checkout@v4
with:
fetch-depth: 1000
submodules: recursive
Expand Down
1 change: 1 addition & 0 deletions codeception.dist.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ coverage:
paths:
tests: tests
log: tests/_output
output: tests/_output
data: tests/_data
helpers: tests/_support
wp_root: "%WP_ROOT_FOLDER%"
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
"stellarwp/arrays": "^1.2.1"
},
"require-dev": {
"lucatume/wp-browser": "^3.2.3",
"lucatume/wp-browser": ">=3.2.3 < 3.5.1",
"szepeviktor/phpstan-wordpress": "^1.1",
"symfony/event-dispatcher-contracts": "^2.5.1",
"symfony/string": "^5.4",
Expand Down
2 changes: 2 additions & 0 deletions tests/_output/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
*
!.gitignore

0 comments on commit 391a805

Please sign in to comment.