Create todos with an ID
This commit is contained in:
parent
9e75b6f9bb
commit
1f16b4bfe0
2 changed files with 18 additions and 1 deletions
|
@ -6,7 +6,17 @@ use PHPUnit\Framework\TestCase;
|
|||
|
||||
class TodoTest extends TestCase
|
||||
{
|
||||
public function testCreateTodo(): void
|
||||
public function testCreateTodo(): void {
|
||||
$todo1 = new Todo("Some title");
|
||||
$todo2 = new Todo("Some title");
|
||||
$this->assertNotEquals(
|
||||
$todo1->getID(),
|
||||
$todo2->getID(),
|
||||
"Expected todos to have different UIDs but they have the same."
|
||||
);
|
||||
}
|
||||
|
||||
public function testTodoHasTitle(): void
|
||||
{
|
||||
$title = "Some task";
|
||||
$todo = new Todo($title);
|
||||
|
|
Reference in a new issue