refactor: rename Application → Aanvraag across the wire (Step 1/8)
The wire said Application, the domain said Aanvraag — one aggregate with two names at every hop. Rename the backend DTOs and the /applications route to /aanvragen, regenerate the typed client, and rename the frontend adapter/store to match. Renamed: ApplicationSummaryDto/DetailDto, CreateApplicationRequest, SubmitApplicationRequest/Response → Aanvraag* equivalents; ApplicationsAdapter/Store → AanvragenAdapter/Store; applications.adapter.ts/applications.store.ts → aanvragen.*. Left untouched: the admin Case/Zaak vocabulary (/admin/cases, AdminCasesStore) — a separate read model, not part of this rename; the internal BigRegister.Domain.Applications namespace and the Applications EF table (renaming those needs a new EF migration, out of scope here). Part of the dashboard-readability refactor (see the approved plan). Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
@@ -35,17 +35,17 @@ public class BeoordelingTests(TestWebApplicationFactory factory) : IClassFixture
|
||||
/// A manual (never auto-approved) case with one linked document, so it stays
|
||||
/// InBehandeling/decidable regardless of test timing (the 8s auto-approval window
|
||||
/// would otherwise make a duo-registratie/herregistratie fixture flaky).
|
||||
private async Task<(ApplicationDetailDto App, string DocumentId)> CreateManualCaseWithDocument()
|
||||
private async Task<(AanvraagDetailDto App, string DocumentId)> CreateManualCaseWithDocument()
|
||||
{
|
||||
var created = await _client.PostAsJsonAsync("/api/v1/applications", new { type = "registratie" });
|
||||
var a = (await created.Content.ReadFromJsonAsync<ApplicationDetailDto>())!;
|
||||
var created = await _client.PostAsJsonAsync("/api/v1/aanvragen", new { type = "registratie" });
|
||||
var a = (await created.Content.ReadFromJsonAsync<AanvraagDetailDto>())!;
|
||||
|
||||
var localId = Guid.NewGuid().ToString();
|
||||
var upload = await _client.PostAsync("/api/v1/uploads", UploadForm(localId, "diploma", "diploma.pdf"));
|
||||
upload.EnsureSuccessStatusCode();
|
||||
var doc = (await upload.Content.ReadFromJsonAsync<UploadResponse>())!;
|
||||
|
||||
var submit = await _client.PostAsJsonAsync($"/api/v1/applications/{a.Id}/submit", new
|
||||
var submit = await _client.PostAsJsonAsync($"/api/v1/aanvragen/{a.Id}/submit", new
|
||||
{
|
||||
diplomaHerkomst = "handmatig",
|
||||
documents = new[] { new { categoryId = "diploma", channel = "digital", documentId = doc.DocumentId } },
|
||||
@@ -88,8 +88,8 @@ public class BeoordelingTests(TestWebApplicationFactory factory) : IClassFixture
|
||||
[Fact]
|
||||
public async Task Concept_and_unknown_id_are_not_found()
|
||||
{
|
||||
var created = await _client.PostAsJsonAsync("/api/v1/applications", new { type = "registratie" });
|
||||
var concept = (await created.Content.ReadFromJsonAsync<ApplicationDetailDto>())!;
|
||||
var created = await _client.PostAsJsonAsync("/api/v1/aanvragen", new { type = "registratie" });
|
||||
var concept = (await created.Content.ReadFromJsonAsync<AanvraagDetailDto>())!;
|
||||
try
|
||||
{
|
||||
var conceptRes = await _client.SendAsync(AsBehandelaar(HttpMethod.Get, $"/api/v1/beoordeling/{concept.Id}"));
|
||||
@@ -100,7 +100,7 @@ public class BeoordelingTests(TestWebApplicationFactory factory) : IClassFixture
|
||||
}
|
||||
finally
|
||||
{
|
||||
await _client.DeleteAsync($"/api/v1/applications/{concept.Id}");
|
||||
await _client.DeleteAsync($"/api/v1/aanvragen/{concept.Id}");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user