test create plan schedules nodes
This commit is contained in:
parent
0ff5043ba5
commit
9d831915de
1 changed files with 21 additions and 0 deletions
|
|
@ -256,4 +256,25 @@ class PlanControllerTest extends TestCase
|
|||
$this->assertNotNull($storedPlan);
|
||||
$this->assertEquals('Persistent Plan', $storedPlan->getName());
|
||||
}
|
||||
|
||||
public function test_create_plan_schedules_nodes(): void
|
||||
{
|
||||
$this->controller->createPlan(
|
||||
$this->makeRequest([
|
||||
'userId' => 0,
|
||||
'textId' => 0,
|
||||
'name' => 'Scheduling Plan',
|
||||
'dateStart' => '2025-01-01',
|
||||
'dateEnd' => '2025-01-01',
|
||||
]),
|
||||
new Response(),
|
||||
$this->createPlan,
|
||||
);
|
||||
|
||||
$this->assertEquals(
|
||||
1,
|
||||
$this->scheduledNodeRepo->getNumberOfTimesCreateCalled()
|
||||
);
|
||||
$this->assertNotNull($this->scheduledNodeRepo->find(0));
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue