mirror of
https://github.com/shlinkio/shlink.git
synced 2026-03-12 01:54:41 +08:00
Improved public API in Tag entity, avoiding anemic model
This commit is contained in:
@@ -11,10 +11,9 @@ class TagTest extends TestCase
|
||||
/**
|
||||
* @test
|
||||
*/
|
||||
public function jsonSerializationOfTagsReturnsItsName()
|
||||
public function jsonSerializationOfTagsReturnsItsStringRepresentation()
|
||||
{
|
||||
$tag = new Tag();
|
||||
$tag->setName('This is my name');
|
||||
$this->assertEquals($tag->getName(), $tag->jsonSerialize());
|
||||
$tag = new Tag('This is my name');
|
||||
$this->assertEquals((string) $tag, $tag->jsonSerialize());
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user