mirror of
https://github.com/vitodeploy/vito.git
synced 2025-04-20 02:11:36 +00:00
25 lines
524 B
PHP
25 lines
524 B
PHP
<?php
|
|
|
|
namespace Tests\Unit\SSHCommands\PHP;
|
|
|
|
use App\SSHCommands\PHP\InstallPHPExtensionCommand;
|
|
use Tests\TestCase;
|
|
|
|
class InstallPHPExtensionCommandTest extends TestCase
|
|
{
|
|
public function test_generate_command()
|
|
{
|
|
$command = new InstallPHPExtensionCommand('8.1', 'imagick');
|
|
|
|
$expected = <<<'EOD'
|
|
sudo apt install -y php8.1-imagick
|
|
|
|
sudo service php8.1-fpm restart
|
|
|
|
php8.1 -m
|
|
EOD;
|
|
|
|
$this->assertStringContainsString($expected, $command->content());
|
|
}
|
|
}
|