fix some phpunit 10.x deprecations

This commit is contained in:
Mike Macgirvin 2024-03-10 17:09:45 +11:00
parent f26b6accbe
commit dd1f55c389
3 changed files with 14 additions and 28 deletions

View file

@ -1,27 +1,13 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/9.6/phpunit.xsd"
bootstrap="bootstrap.php"
cacheResultFile=".phpunit.cache/test-results"
executionOrder="depends,defects"
forceCoversAnnotation="false"
beStrictAboutCoversAnnotation="true"
beStrictAboutOutputDuringTests="true"
beStrictAboutTodoAnnotatedTests="true"
convertDeprecationsToExceptions="true"
failOnRisky="true"
failOnWarning="true"
verbose="true">
<testsuites>
<testsuite name="default">
<directory>../tests</directory>
</testsuite>
</testsuites>
<coverage cacheDirectory=".phpunit.cache/code-coverage"
processUncoveredFiles="true">
<include>
<directory suffix=".php">.</directory>
</include>
</coverage>
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/10.5/phpunit.xsd" bootstrap="bootstrap.php" executionOrder="depends,defects" beStrictAboutOutputDuringTests="true" failOnRisky="true" failOnWarning="true" cacheDirectory=".phpunit.cache" requireCoverageMetadata="false" beStrictAboutCoverageMetadata="true">
<testsuites>
<testsuite name="default">
<directory>../tests</directory>
</testsuite>
</testsuites>
<source>
<include>
<directory suffix=".php">.</directory>
</include>
</source>
</phpunit>

View file

@ -49,7 +49,7 @@ class HttpSigTest extends UnitTestCase
);
}
public function generate_digestProvider()
public static function generate_digestProvider()
{
return [
'empty body text' => [

View file

@ -91,7 +91,7 @@ empty line above';
{
$this->assertEquals($expected, notags($string));
}
public function notagsProvider()
public static function notagsProvider()
{
return [
'empty string' => ['', ''],
@ -110,7 +110,7 @@ empty line above';
sanitise_acl($string);
$this->assertEquals($expected, $string);
}
public function sanitise_aclProvider()
public static function sanitise_aclProvider()
{
return [
'text' => ['value', '<value>'],