Skip to content

Commit bc33bb3

Browse files
committed
added unit test
1 parent 7511c38 commit bc33bb3

File tree

2 files changed

+8
-3
lines changed

2 files changed

+8
-3
lines changed

src/Deploy.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,15 +58,15 @@ public function __construct($directory, $branch = 'master', $remote = 'origin',
5858
$logger = new Logger('Deployment');
5959
}
6060
$this->setLogger($logger);
61-
62-
$this->logger->info('Attempting deployment...');
6361
}
6462

6563
/**
6664
* Executes the necessary commands to deploy the website.
6765
*/
6866
public function execute()
6967
{
68+
$this->logger->info('Attempting deployment...');
69+
7070
try
7171
{
7272
// Make sure we're in the right directory

tests/DeployTest.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,12 @@
22

33
namespace Tylercd100\GitDeploy\Tests;
44

5+
use Tylercd100\GitDeploy\Deploy;
6+
57
class DeployTest extends TestCase
68
{
7-
9+
public function testItCreatesInstanceSuccessfully()
10+
{
11+
$obj = new Deploy(__DIR__);
12+
}
813
}

0 commit comments

Comments
 (0)