Filter the script library and show customer context across pages

This commit is contained in:
2026-11-18 09:28:11 +01:00
parent f8e5865412
commit 97ef5783c1
7 changed files with 97 additions and 22 deletions
+10
View File
@@ -100,7 +100,17 @@ test('creates and renames a customer, opens its inventory, and hides editing for
await page.getByRole('button', { name: 'Geräte von Nord GmbH anzeigen' }).click();
await expect(page.getByRole('heading', { name: 'Geräte', exact: true })).toBeVisible();
await expect(page.getByRole('combobox', { name: 'Kunde', exact: true })).toHaveValue(customerId);
await expect(page.getByRole('combobox', { name: 'Kunde im Gerätebestand', exact: true })).toHaveValue(customerId);
await expect(page.getByRole('row').filter({ hasText: 'NORD-PC' })).toContainText('Nord GmbH');
const navigation = page.getByRole('navigation', { name: 'Hauptnavigation' });
await navigation.getByRole('link', { name: 'Aufträge', exact: true }).click();
await expect(page.getByRole('combobox', { name: 'Kunde', exact: true })).toHaveValue(customerId);
await navigation.getByRole('link', { name: 'Skripte', exact: true }).click();
await expect(page.getByRole('combobox', { name: 'Kunde', exact: true })).toHaveValue(customerId);
await navigation.getByRole('link', { name: 'Genehmigungen', exact: true }).click();
await expect(page.locator('header').getByText('Nord GmbH')).toBeVisible();
await navigation.getByRole('link', { name: 'Geräte', exact: true }).click();
await expect(page.getByRole('combobox', { name: 'Kunde im Gerätebestand', exact: true })).toHaveValue(customerId);
expect(mutations).toEqual([
{ method: 'POST', path: '/api/v1/tenants', body: { name: 'Nord' } },
{ method: 'PATCH', path: `/api/v1/tenants/${customerId}`, body: { name: 'Nord GmbH' } }