<?php

namespace TestBusinessClass;

use BusinessClass\Keyword;
use PHPUnit\Framework\TestCase;

class KeywordTest extends TestCase
{
    public function testConstructor()
    {
        $id = 1;
        $word = 'example';
        $keyword = new Keyword($id, $word);

        $this->assertEquals($id, $keyword->getId());
        $this->assertEquals($word, $keyword->getWord());
    }

    public function testSetWord()
    {
        $id = 1;
        $word = 'example';
        $newWord = 'new example';
        $keyword = new Keyword($id, $word);
        $keyword->setWord($newWord);

        $this->assertEquals($newWord, $keyword->getWord());
    }
}

