Skip to content
Snippets Groups Projects
Unverified Commit d5f39164 authored by Lukas Reschke's avatar Lukas Reschke
Browse files

Add test for setTopmostParentId and getTopmostParentId


This wasn't tested before as proven by the coverage data.

Signed-off-by: default avatarLukas Reschke <lukas@statuscode.ch>
parent 938b0d55
No related branches found
No related tags found
No related merge requests found
...@@ -12,6 +12,7 @@ class CommentTest extends TestCase { ...@@ -12,6 +12,7 @@ class CommentTest extends TestCase {
$id = 'comment23'; $id = 'comment23';
$parentId = 'comment11.5'; $parentId = 'comment11.5';
$topMostParentId = 'comment11.0';
$childrenCount = 6; $childrenCount = 6;
$message = 'I like to comment comment'; $message = 'I like to comment comment';
$verb = 'comment'; $verb = 'comment';
...@@ -23,6 +24,7 @@ class CommentTest extends TestCase { ...@@ -23,6 +24,7 @@ class CommentTest extends TestCase {
$comment $comment
->setId($id) ->setId($id)
->setParentId($parentId) ->setParentId($parentId)
->setTopmostParentId($topMostParentId)
->setChildrenCount($childrenCount) ->setChildrenCount($childrenCount)
->setMessage($message) ->setMessage($message)
->setVerb($verb) ->setVerb($verb)
...@@ -33,6 +35,7 @@ class CommentTest extends TestCase { ...@@ -33,6 +35,7 @@ class CommentTest extends TestCase {
$this->assertSame($id, $comment->getId()); $this->assertSame($id, $comment->getId());
$this->assertSame($parentId, $comment->getParentId()); $this->assertSame($parentId, $comment->getParentId());
$this->assertSame($topMostParentId, $comment->getTopmostParentId());
$this->assertSame($childrenCount, $comment->getChildrenCount()); $this->assertSame($childrenCount, $comment->getChildrenCount());
$this->assertSame($message, $comment->getMessage()); $this->assertSame($message, $comment->getMessage());
$this->assertSame($verb, $comment->getVerb()); $this->assertSame($verb, $comment->getVerb());
...@@ -65,6 +68,7 @@ class CommentTest extends TestCase { ...@@ -65,6 +68,7 @@ class CommentTest extends TestCase {
public function simpleSetterProvider() { public function simpleSetterProvider() {
return [ return [
['Id', true], ['Id', true],
['TopmostParentId', true],
['ParentId', true], ['ParentId', true],
['Message', true], ['Message', true],
['Verb', true], ['Verb', true],
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment