From 4f2562316b1c37602f0250a612e3f3910f5ad380 Mon Sep 17 00:00:00 2001 From: Matteo Beccati Date: Sun, 5 Oct 2025 09:47:44 +0200 Subject: [PATCH] Skip test when pie can't enable the extension --- test/integration/Command/ShowCommandTest.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/test/integration/Command/ShowCommandTest.php b/test/integration/Command/ShowCommandTest.php index 4fc7358b..be348fd6 100644 --- a/test/integration/Command/ShowCommandTest.php +++ b/test/integration/Command/ShowCommandTest.php @@ -19,6 +19,7 @@ use function get_loaded_extensions; use function phpversion; +use function str_contains; use const PHP_VERSION_ID; @@ -70,6 +71,12 @@ public function testExecuteWithAvailableUpdates(): void ]); $installCommand->assertCommandIsSuccessful(); + $outputString = $installCommand->getDisplay(); + + if (str_contains($outputString, 'NOT been automatically')) { + self::markTestSkipped('PIE couldn\'t automatically enable the extension'); + } + PieJsonEditor::fromTargetPlatform( PiePlatform\TargetPlatform::fromPhpBinaryPath( PiePlatform\TargetPhp\PhpBinaryPath::fromPhpConfigExecutable(