1
0
Fork 0

Create todos with an ID

This commit is contained in:
Marcel Kapfer 2021-09-20 13:00:01 +02:00
parent 9e75b6f9bb
commit 1f16b4bfe0
Signed by: mmk2410
GPG key ID: CADE6F0C09F21B09
2 changed files with 18 additions and 1 deletions

View file

@ -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);