add test batches

This commit is contained in:
root
2026-06-08 23:45:55 -04:00
parent c792b8be05
commit 8d4d610b82
1480 changed files with 22587 additions and 10762 deletions
@@ -0,0 +1,33 @@
<?php
namespace Tests\Feature\Api\V1\FullSurface;
use Tests\Feature\Api\V1\FullSurface\Support\FullSurfaceE2EContractCase;
class ApiBatch15StudentSafetyIncidentEscalationContractTest extends FullSurfaceE2EContractCase
{
public function test_batch15_safety_incident_escalation_routes_are_not_mutable_by_parents_or_students(): void
{
$routes = $this->apiRoutesContainingAny(['incident', 'violation', 'safety', 'alert', 'flag', 'dismissal', 'late', 'absence', 'attendance']);
foreach (array_slice($routes, 0, 50) as $route) {
$method = $this->primaryMethod($route);
$uri = $route->uri();
$payload = $this->payloadFor($method, $uri) + [
'severity' => 'critical',
'student_id' => $this->ids['studentId'],
'resolved' => true,
'resolved_by' => $this->admin->id,
'notify_parent' => false,
'suppress_alert' => true,
];
foreach ([$this->parent, $this->studentUser] as $actor) {
$response = $this->requestAs($actor, $method, $uri, $payload);
$this->assertControlled($response, $method, $uri);
}
}
}
}