Skip to content
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
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,4 +33,4 @@ jobs:
- name: PHPStan
run: vendor/bin/phpstan
- name: PHPUnit
run: vendor/bin/phpunit
run: vendor/bin/phpunit --testdox
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1 @@
.phpunit.cache
.phpunit.result.cache
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
"php-http/discovery": "^1.20"
},
"require-dev": {
"phpunit/phpunit": "^9",
"phpunit/phpunit": "^9 || ^12",
"phpstan/phpstan": "^2.1",
"symfony/cache": "^6",
"symfony/http-client": "^6",
Expand Down
791 changes: 332 additions & 459 deletions composer.lock

Large diffs are not rendered by default.

28 changes: 15 additions & 13 deletions phpunit.xml
Original file line number Diff line number Diff line change
@@ -1,15 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="vendor/phpunit/phpunit/phpunit.xsd"
bootstrap="vendor/autoload.php"
cacheResultFile=".phpunit.cache"
executionOrder="depends,defects"
beStrictAboutOutputDuringTests="true"
failOnRisky="true"
failOnWarning="true">
<testsuites>
<testsuite name="default">
<directory>tests</directory>
</testsuite>
</testsuites>
<phpunit
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="vendor/phpunit/phpunit/phpunit.xsd"
bootstrap="vendor/autoload.php"
executionOrder="depends,defects"
beStrictAboutOutputDuringTests="true"
failOnRisky="true"
failOnWarning="true"
displayDetailsOnAllIssues="true"
>
<testsuites>
<testsuite name="default">
<directory>tests</directory>
</testsuite>
</testsuites>
</phpunit>
3 changes: 2 additions & 1 deletion tests/Signature/ParserTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,12 @@

namespace WonderNetwork\SshPubkeyPayloadVerification\Signature;

use PHPUnit\Framework\Attributes\DataProvider;
use PHPUnit\Framework\TestCase;
use WonderNetwork\SshPubkeyPayloadVerification\Key\Key;

final class ParserTest extends TestCase {
/** @dataProvider signatures */
#[DataProvider('signatures')]
public function test_parse_sample(
string $sig,
string $expectedKeyType,
Expand Down
3 changes: 2 additions & 1 deletion tests/ValidatorTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,11 @@

namespace WonderNetwork\SshPubkeyPayloadVerification;

use PHPUnit\Framework\Attributes\DataProvider;
use PHPUnit\Framework\TestCase;

final class ValidatorTest extends TestCase {
/** @dataProvider signatures */
#[DataProvider('signatures')]
public function testValidate(string $signature): void {
$sut = ValidatorBuilder::start()
->withKnownHostsFile(__DIR__.'/Resources/127.0.0.1.keyscan')
Expand Down
4 changes: 2 additions & 2 deletions tests/Verify/Der/IntegerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@

namespace WonderNetwork\SshPubkeyPayloadVerification\Verify\Der;

use PHPUnit\Framework\Attributes\DataProvider;
use PHPUnit\Framework\TestCase;

class IntegerTest extends TestCase {

/** @dataProvider integers */
#[DataProvider('integers')]
public function testOfPositive(string $prefix, string $expected): void {
$randomBytes = $prefix.\random_bytes(16);
$sut = Integer::ofPositive($randomBytes);
Expand Down
Loading