Commit dd117ff0 authored by Mark Harding's avatar Mark Harding

(fix): test for summonsing

1 merge request!100Epic/reporting and moderation
Pipeline #62750190 canceled with stages
......@@ -6,6 +6,7 @@ use Minds\Core\Queue\Interfaces\QueueClient;
use Minds\Core\Queue\Runners\ReportsAppealSummon;
use Minds\Core\Reports\Appeals\Appeal;
use Minds\Core\Reports\Appeals\Delegates\SummonDelegate;
use Minds\Core\Reports\Report;
use PhpSpec\ObjectBehavior;
use Prophecy\Argument;
......@@ -27,14 +28,20 @@ class SummonDelegateSpec extends ObjectBehavior
$this->shouldHaveType(SummonDelegate::class);
}
function it_should_queue_on_appeal(Appeal $appeal)
function it_should_queue_on_appeal(Report $report)
{
$report = new Report();
$report->setReasonCode(2);
$appeal = new Appeal();
$appeal->setReport($report);
$this->queue->setQueue('ReportsAppealSummon')
->shouldBeCalled()
->willReturn($this->queue);
$this->queue->send([
'appeal' => $appeal,
'appeal' => serialize($appeal),
'cohort' => null,
])
->shouldBeCalled();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment