Skip to content

Commit f3cfb9a

Browse files
ruudkNyholm
andauthored
Fix master (#258)
* Migrate PHPUnit configuration to new format * Replace assertRegExp * Add void * Remove coverage from PHPUnit config It's not expected anymore. * Use `$this->expectException` instead of comment * Ignore some tests * Only PHP >7.4 Co-authored-by: Nyholm <[email protected]>
1 parent da5e3bc commit f3cfb9a

File tree

3 files changed

+3
-25
lines changed

3 files changed

+3
-25
lines changed

Tests/CreateServerTrait.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ public function getCollection()
3737
return $this->collection;
3838
}
3939

40-
public static function setUpBeforeClass()
40+
public static function setUpBeforeClass(): void
4141
{
4242
if (!class_exists('\MongoDB\Collection')) {
4343
static::markTestSkipped('MonogoDB extension not installed.');

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
],
2424
"homepage": "http://www.php-cache.com/en/latest/",
2525
"require": {
26-
"php": "^7.1 || ^8.0",
26+
"php": ">=7.4",
2727
"cache/adapter-common": "^1.1",
2828
"mongodb/mongodb": "^1.0",
2929
"psr/cache": "^1.0 || ^2.0",

phpunit.xml.dist

Lines changed: 1 addition & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,40 +1,18 @@
11
<?xml version="1.0" encoding="UTF-8"?>
2-
3-
<phpunit backupGlobals="false"
4-
backupStaticAttributes="false"
5-
colors="true"
6-
convertErrorsToExceptions="true"
7-
convertNoticesToExceptions="true"
8-
convertWarningsToExceptions="true"
9-
processIsolation="false"
10-
stopOnFailure="false"
11-
bootstrap="vendor/autoload.php"
12-
>
2+
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" backupGlobals="false" backupStaticAttributes="false" colors="true" convertErrorsToExceptions="true" convertNoticesToExceptions="true" convertWarningsToExceptions="true" processIsolation="false" stopOnFailure="false" bootstrap="vendor/autoload.php" xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/9.3/phpunit.xsd">
133
<testsuites>
144
<testsuite name="Main Test Suite">
155
<directory>./Tests/</directory>
166
</testsuite>
177
</testsuites>
18-
198
<php>
209
<env name="MONGODB_HOST" value="localhost:27017"/>
2110
<env name="MONGODB_COLLECTION" value="psr6test.cache"/>
2211
<env name="MONGODB_DATABASE" value="test"/>
2312
</php>
24-
2513
<groups>
2614
<exclude>
2715
<group>benchmark</group>
2816
</exclude>
2917
</groups>
30-
31-
<filter>
32-
<whitelist>
33-
<directory>./</directory>
34-
<exclude>
35-
<directory>./Tests</directory>
36-
<directory>./vendor</directory>
37-
</exclude>
38-
</whitelist>
39-
</filter>
4018
</phpunit>

0 commit comments

Comments
 (0)