vito/tests/Unit/SSHCommands/Storage/UploadToFTPCommandTest.php
Saeed Vaziry f70963d6bb
fix notification chanels and more tests (#108)
* fix notification chanels and more tests

* fix code style
2024-02-16 21:10:17 +01:00

30 lines
640 B
PHP

<?php
namespace Tests\Unit\SSHCommands\Storage;
use App\SSHCommands\Storage\UploadToFTPCommand;
use Tests\TestCase;
class UploadToFTPCommandTest extends TestCase
{
public function test_generate_command()
{
$command = new UploadToFTPCommand(
'src',
'dest',
'1.1.1.1',
'21',
'username',
'password',
true,
true
);
$expected = <<<'EOD'
curl --ftp-pasv -T "src" -u "username:password" ftps://1.1.1.1:21/dest
EOD;
$this->assertStringContainsString($expected, $command->content());
}
}