style(web): format webhook parity regression

Preserve both accepted candidate changes while satisfying the repository's Prettier check on the newly added regression.

Change-source: pulse-maintainer
This commit is contained in:
pulse-triage[bot]
2026-09-08 23:50:18 +01:00
parent ff34fa42de
commit b825735173
@@ -1590,17 +1590,29 @@ describe('webhook test/save parity', () => {
const onTest = vi.fn();
const onAdd = vi.fn();
const state = useWebhookConfigState({
webhooks: [], onTest, onAdd, onUpdate: vi.fn(), onDelete: vi.fn(),
webhooks: [],
onTest,
onAdd,
onUpdate: vi.fn(),
onDelete: vi.fn(),
});
state.openAddForm();
state.setFormData((data) => ({ ...data, name: 'Example', url: 'https://example.invalid', service: 'pushover' }));
state.setFormData((data) => ({
...data,
name: 'Example',
url: 'https://example.invalid',
service: 'pushover',
}));
for (const [index, key] of ['app_token', 'user_token'].entries()) {
state.addCustomFieldInput();
state.updateCustomFieldInput(index, { key, value: `synthetic-${index}` });
}
state.testWebhookForm();
state.saveWebhook();
expect(onAdd.mock.calls[0][0].customFields).toEqual({ token: 'synthetic-0', user: 'synthetic-1' });
expect(onAdd.mock.calls[0][0].customFields).toEqual({
token: 'synthetic-0',
user: 'synthetic-1',
});
expect(onTest.mock.calls[0][1].customFields).toEqual(onAdd.mock.calls[0][0].customFields);
} finally {
dispose();