Skip to content

Commit a2e0cce

Browse files
committed
Remove duplicate key-string methods after PR merge
1 parent 9b55908 commit a2e0cce

2 files changed

Lines changed: 0 additions & 26 deletions

File tree

src/SSHConnection.php

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -64,12 +64,6 @@ public function withPrivateKeyString(string $privateKeyContents): self
6464
return $this;
6565
}
6666

67-
public function withPrivateKeyString(string $privateKeyContents): self
68-
{
69-
$this->privateKeyContents = $privateKeyContents;
70-
return $this;
71-
}
72-
7367
public function timeout(int $timeout): self
7468
{
7569
$this->timeout = $timeout;

tests/Integration/SSHConnectionTest.php

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -90,26 +90,6 @@ public function testSSHConnectionWithKeyContents()
9090
$this->assertSame('', $command->getRawError());
9191
}
9292

93-
public function testSSHConnectionWithKeyContents()
94-
{
95-
$privateKeyContents = file_get_contents('/home/travis/.ssh/id_rsa');
96-
97-
$connection = (new SSHConnection())
98-
->to('localhost')
99-
->onPort(22)
100-
->as('travis')
101-
->withPrivateKeyString($privateKeyContents)
102-
->connect();
103-
104-
$command = $connection->run('echo "Hello world!"');
105-
106-
$this->assertEquals('Hello world!', $command->getOutput());
107-
$this->assertEquals('Hello world!'."\n", $command->getRawOutput());
108-
109-
$this->assertEquals('', $command->getError());
110-
$this->assertEquals('', $command->getRawError());
111-
}
112-
11393
public function testSSHConnectionWithPassword()
11494
{
11595
$connection = $this->createPasswordConnection();

0 commit comments

Comments
 (0)