1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37
|
From: =?utf-8?q?David_Pr=C3=A9vot?= <taffit@debian.org>
Date: Mon, 20 May 2024 11:58:08 +0200
Subject: Group nophpunit11 for tests failing with PHPUnit 11
Bug-Debian: https://bugs.debian.org/1070504
---
tests/Composer/Test/Command/SelfUpdateCommandTest.php | 3 +++
1 file changed, 3 insertions(+)
diff --git a/tests/Composer/Test/Command/SelfUpdateCommandTest.php b/tests/Composer/Test/Command/SelfUpdateCommandTest.php
index b0589b2..9a6dac8 100644
--- a/tests/Composer/Test/Command/SelfUpdateCommandTest.php
+++ b/tests/Composer/Test/Command/SelfUpdateCommandTest.php
@@ -14,6 +14,7 @@ namespace Composer\Test\Command;
use Composer\Composer;
use Composer\Test\TestCase;
+use PHPUnit\Framework\Attributes\RequiresPhpunit;
use Symfony\Component\Process\Process;
/**
@@ -49,6 +50,7 @@ class SelfUpdateCommandTest extends TestCase
self::assertStringContainsString('Upgrading to version', $appTester->getOutput());
}
+ #[RequiresPhpunit('< 11')]
public function testUpdateToSpecificVersion(): void
{
$appTester = new Process([PHP_BINARY, $this->phar, 'self-update', '2.4.0']);
@@ -70,6 +72,7 @@ class SelfUpdateCommandTest extends TestCase
/**
* @dataProvider channelOptions
*/
+ #[RequiresPhpunit('< 11')]
public function testUpdateToDifferentChannel(string $option, string $expectedOutput): void
{
if (Composer::VERSION !== '@package_version'.'@' && in_array($option, ['--stable', '--preview'], true)) {
|