Skip to content

Commit 8fdeefb

Browse files
Added first meaningless tests
1 parent ba60046 commit 8fdeefb

File tree

3 files changed

+49
-0
lines changed

3 files changed

+49
-0
lines changed

tests/.gitkeep

Whitespace-only changes.

tests/TwilioCallCommandTest.php

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
<?php
2+
namespace Aloha\Twilio\Tests;
3+
4+
use Aloha\Twilio\Commands\TwilioCallCommand;
5+
use Aloha\Twilio\Twilio;
6+
use PHPUnit_Framework_TestCase;
7+
8+
class TwilioCallCommandTest extends PHPUnit_Framework_TestCase
9+
{
10+
/**
11+
* Test the name of the command
12+
*/
13+
public function testName()
14+
{
15+
// Arrange
16+
$stub = $this->getMock('Aloha\Twilio\TwilioInterface');
17+
$command = new TwilioCallCommand($stub);
18+
19+
// Act
20+
$name = $command->getName();
21+
22+
// Assert
23+
$this->assertEquals('twilio:call', $name);
24+
}
25+
}

tests/TwilioSmsCommandTest.php

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
<?php
2+
namespace Aloha\Twilio\Tests;
3+
4+
use Aloha\Twilio\Commands\TwilioSmsCommand;
5+
use PHPUnit_Framework_TestCase;
6+
7+
class TwilioSmsCommandTest extends PHPUnit_Framework_TestCase
8+
{
9+
/**
10+
* Test the name of the command
11+
*/
12+
public function testName()
13+
{
14+
// Arrange
15+
$stub = $this->getMock('Aloha\Twilio\TwilioInterface');
16+
$command = new TwilioSmsCommand($stub);
17+
18+
// Act
19+
$name = $command->getName();
20+
21+
// Assert
22+
$this->assertEquals('twilio:sms', $name);
23+
}
24+
}

0 commit comments

Comments
 (0)