diff options
author | Joas Schilling <coding@schilljs.com> | 2024-07-01 16:59:47 +0200 |
---|---|---|
committer | Joas Schilling <coding@schilljs.com> | 2024-07-19 11:21:14 +0200 |
commit | 829f2b9bc7290c0b1b1a9db373ee26199c9bcc4d (patch) | |
tree | 5641e35ffe42897566f58acb1d71a0d9afba4729 /tests/lib/Files/Cache/CacheTest.php | |
parent | bd383627a7ef3cb0a8e608b35de067d341f46da4 (diff) | |
download | nextcloud-server-829f2b9bc7290c0b1b1a9db373ee26199c9bcc4d.tar.gz nextcloud-server-829f2b9bc7290c0b1b1a9db373ee26199c9bcc4d.zip |
fix(db): Promote the use of `getDatabaseProvider` to reduce the impage of removed upstream platforms
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'tests/lib/Files/Cache/CacheTest.php')
-rw-r--r-- | tests/lib/Files/Cache/CacheTest.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/lib/Files/Cache/CacheTest.php b/tests/lib/Files/Cache/CacheTest.php index faecbf54491..a36607eb965 100644 --- a/tests/lib/Files/Cache/CacheTest.php +++ b/tests/lib/Files/Cache/CacheTest.php @@ -7,12 +7,12 @@ namespace Test\Files\Cache; -use Doctrine\DBAL\Platforms\MySqlPlatform; use OC\Files\Cache\Cache; use OC\Files\Search\SearchComparison; use OC\Files\Search\SearchQuery; use OCP\EventDispatcher\IEventDispatcher; use OCP\Files\Search\ISearchComparison; +use OCP\IDBConnection; use OCP\IUser; class LongId extends \OC\Files\Storage\Temporary { @@ -142,7 +142,7 @@ class CacheTest extends \Test\TestCase { if (strpos($folder, 'F09F9890')) { // 4 byte UTF doesn't work on mysql $params = \OC::$server->get(\OC\DB\Connection::class)->getParams(); - if (\OC::$server->getDatabaseConnection()->getDatabasePlatform() instanceof MySqlPlatform && $params['charset'] !== 'utf8mb4') { + if (\OC::$server->getDatabaseConnection()->getDatabaseProvider() === IDBConnection::PLATFORM_MYSQL && $params['charset'] !== 'utf8mb4') { $this->markTestSkipped('MySQL doesn\'t support 4 byte UTF-8'); } } |