Skip to content

Update test matrix to include full MySQL 8 and MySQL 9 support #209

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 27, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,10 @@ jobs:
- 5.5
- 5.4
include:
- php: 8.4
rdbms: mysql:9
- php: 8.4
rdbms: mysql:8
- php: 8.4
rdbms: mariadb:10
steps:
Expand Down
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -416,6 +416,12 @@ extensions and supports running on legacy PHP 5.4 through current PHP 8+ and
HHVM.
It's *highly recommended to use the latest supported PHP version* for this project.

This project supports connecting to a variety of MySQL database versions and
compatible projects using the MySQL protocol. The `caching_sha2_password`
authentication plugin (default in MySQL 8+) requires PHP 7.1+ and `ext-openssl`
to be installed, while the older `mysql_native_password` authentication plugin
(default in MySQL 5.7) is supported across all supported PHP versions.

## Tests

To run the test suite, you first need to clone this repo and then install all
Expand Down
3 changes: 2 additions & 1 deletion tests/NoResultQueryTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,8 @@ public function testCreateTableAgainWillAddWarning()
)';

$connection->query($sql)->then(function (MysqlResult $command) {
$this->assertEquals(1, $command->warningCount);
// 3 warnings on MySQL 8+, 1 warning on legacy MySQL 5
$this->assertGreaterThanOrEqual(1, $command->warningCount);
Comment on lines +79 to +80
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not for this PR, but would it be worth it detecting the MySQL version and adjusting the number here based on that?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not opposed, but given the nature of this test, I don't think this has particularly high priority. PRs welcome I suppose 👍

});

$connection->quit();
Expand Down