From ce49dbd72e930472eb6aeab230ed0d222cea7ea1 Mon Sep 17 00:00:00 2001 From: jrfnl Date: Sun, 6 Feb 2022 10:11:56 +0100 Subject: [PATCH] BaseLineTest: stabilize the message checks ... by using the constant instead of the actual content of the message. --- tests/IntegrationTest/BaseLineTest.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tests/IntegrationTest/BaseLineTest.php b/tests/IntegrationTest/BaseLineTest.php index 8c635346..98420d3d 100644 --- a/tests/IntegrationTest/BaseLineTest.php +++ b/tests/IntegrationTest/BaseLineTest.php @@ -10,6 +10,7 @@ namespace Dealerdirect\Composer\Plugin\Installers\PHPCodeSniffer\Tests\IntegrationTest; +use Dealerdirect\Composer\Plugin\Installers\PHPCodeSniffer\Plugin; use Dealerdirect\Composer\Plugin\Installers\PHPCodeSniffer\Tests\PHPCSVersions; use Dealerdirect\Composer\Plugin\Installers\PHPCodeSniffer\Tests\TestCase; @@ -71,7 +72,7 @@ public function testBaseLineGlobal($phpcsVersion, $expectedStnds) $this->assertComposerValidates(static::$tempGlobalPath); // Make sure the plugin runs. - $expectedStdOut = $this->willPluginOutputShow() ? 'Running PHPCodeSniffer Composer Installer' : null; + $expectedStdOut = $this->willPluginOutputShow() ? Plugin::MESSAGE_RUNNING_INSTALLER : null; $this->assertExecute( 'composer global install -v --no-ansi', 0, // Expected exit code. @@ -115,7 +116,7 @@ public function testBaseLineLocal($phpcsVersion, $expectedStnds) $this->assertComposerValidates(static::$tempLocalPath); // Make sure the plugin runs. - $expectedStdOut = $this->willPluginOutputShow() ? 'Running PHPCodeSniffer Composer Installer' : null; + $expectedStdOut = $this->willPluginOutputShow() ? Plugin::MESSAGE_RUNNING_INSTALLER : null; $this->assertExecute( sprintf('composer install -v --no-ansi --working-dir=%s', escapeshellarg(static::$tempLocalPath)), 0, // Expected exit code.