feat: enhance type safety in security API and related tests

This commit is contained in:
GitHub Actions
2025-12-06 02:57:51 +00:00
parent 8e2ba14ae5
commit 8ef1e7cda0
12 changed files with 67 additions and 50 deletions

View File

@@ -133,7 +133,7 @@ describe('useSecurity hooks', () => {
describe('useCreateDecision', () => {
it('should create decision and invalidate queries', async () => {
const payload = { ip: '1.2.3.4', duration: '4h', type: 'ban' }
const payload = { value: '1.2.3.4', duration: '4h', type: 'ban' }
vi.mocked(securityApi.createDecision).mockResolvedValue({ success: true })
const { result } = renderHook(() => useCreateDecision(), { wrapper })