Tickets: edit comments and mark them as deleted

This commit is contained in:
2025-07-11 12:56:19 +00:00
parent 568c8be7fd
commit 3400656d7c
25 changed files with 945 additions and 7 deletions

View File

@@ -15,6 +15,7 @@ use Chill\TicketBundle\Action\Ticket\Handler\AddCommentCommandHandler;
use Chill\TicketBundle\Controller\AddCommentController;
use Chill\TicketBundle\Entity\Comment;
use Chill\TicketBundle\Entity\Ticket;
use Chill\TicketBundle\Security\Voter\CommentVoter;
use Doctrine\ORM\EntityManagerInterface;
use Prophecy\Argument;
use Prophecy\PhpUnit\ProphecyTrait;
@@ -87,6 +88,7 @@ class AddCommentControllerTest extends KernelTestCase
$entityManager = $this->prophesize(EntityManagerInterface::class);
if ($willFlush) {
$security->isGranted(CommentVoter::CREATE, Argument::type(Comment::class))->willReturn(true);
$entityManager->persist(Argument::type(Comment::class))->shouldBeCalled();
$entityManager->flush()->shouldBeCalled();
}