mirror of
https://github.com/OPSnet/bencode-torrent.git
synced 2026-01-16 20:04:48 -05:00
Update minimum PHP to 8.1
This commit is contained in:
2
.github/workflows/test.yml
vendored
2
.github/workflows/test.yml
vendored
@@ -12,7 +12,7 @@ jobs:
|
||||
|
||||
strategy:
|
||||
matrix:
|
||||
php-version: ['7.2', '7.3', '7.4', '8.0']
|
||||
php-version: ['8.1', '8.2']
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
@@ -15,13 +15,13 @@
|
||||
}
|
||||
},
|
||||
"require": {
|
||||
"php": ">=7.2",
|
||||
"php": ">=8.1",
|
||||
"ext-mbstring": "*"
|
||||
},
|
||||
"require-dev": {
|
||||
"phpunit/phpunit": "^8",
|
||||
"squizlabs/php_codesniffer": "3.*",
|
||||
"phpstan/phpstan": "^0.12.48"
|
||||
"phpunit/phpunit": "^10.4.1",
|
||||
"squizlabs/php_codesniffer": "^3.7.2",
|
||||
"phpstan/phpstan": "^1.10.38"
|
||||
},
|
||||
"scripts": {
|
||||
"test": "phpunit",
|
||||
|
||||
39
phpunit.xml
39
phpunit.xml
@@ -1,19 +1,20 @@
|
||||
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/6.5/phpunit.xsd"
|
||||
colors="true"
|
||||
bootstrap="vendor/autoload.php">
|
||||
<testsuites>
|
||||
<testsuite name="unit">
|
||||
<directory>tests</directory>
|
||||
</testsuite>
|
||||
</testsuites>
|
||||
<filter>
|
||||
<whitelist processUncoveredFilesFromWhitelist="true">
|
||||
<directory suffix=".php">src</directory>
|
||||
<exclude />
|
||||
</whitelist>
|
||||
</filter>
|
||||
<logging>
|
||||
<log type="coverage-html" target="report" />
|
||||
</logging>
|
||||
</phpunit>
|
||||
<?xml version="1.0"?>
|
||||
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/10.4/phpunit.xsd" colors="true" bootstrap="vendor/autoload.php" cacheDirectory=".phpunit.cache">
|
||||
<coverage>
|
||||
<report>
|
||||
<html outputDirectory="report"/>
|
||||
</report>
|
||||
</coverage>
|
||||
<testsuites>
|
||||
<testsuite name="unit">
|
||||
<directory>tests</directory>
|
||||
</testsuite>
|
||||
</testsuites>
|
||||
<logging/>
|
||||
<source>
|
||||
<include>
|
||||
<directory suffix=".php">src</directory>
|
||||
</include>
|
||||
<exclude/>
|
||||
</source>
|
||||
</phpunit>
|
||||
|
||||
@@ -6,7 +6,7 @@ namespace OrpheusNET\BencodeTorrent;
|
||||
|
||||
class BencodeTest extends \PHPUnit\Framework\TestCase
|
||||
{
|
||||
public function dataProvider(): array
|
||||
public static function dataProvider(): array
|
||||
{
|
||||
return [
|
||||
['i0e', 0],
|
||||
@@ -47,7 +47,7 @@ class BencodeTest extends \PHPUnit\Framework\TestCase
|
||||
$bencode->decodeString('di1e5:valuee');
|
||||
}
|
||||
|
||||
public function invalidIntegers(): array
|
||||
public static function invalidIntegers(): array
|
||||
{
|
||||
return [['-0'], ['a'], ['1.0']];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user