Merge pull request #977 from nowcommunity/copilot/sub-pr-976

Fix TypeScript compilation and linting errors in locality synonym tests
This commit is contained in:
Kari Lintulaakso
2025-11-17 13:44:53 +02:00
committed by GitHub
2 changed files with 3 additions and 1 deletions
@@ -190,7 +190,7 @@ export const LocalityTab = () => {
if (!trimmedValue) return 'Synonym is required'
if (trimmedValue.length > 30) return 'Synonym must be 30 characters or fewer'
const duplicate = editData.now_syn_loc.some(existing => {
const duplicate = editData.now_syn_loc.some((existing: Editable<LocalitySynonym>) => {
if (existing.rowState === 'removed' || existing.rowState === 'cancelled') return false
return (existing.synonym ?? '').trim().toLowerCase() === trimmedValue.toLowerCase()
})
@@ -1,3 +1,5 @@
/* eslint-disable @typescript-eslint/no-unsafe-assignment */
/* eslint-disable @typescript-eslint/no-unsafe-member-access */
import { beforeEach, describe, expect, it, jest } from '@jest/globals'
import { render, screen, waitFor } from '@testing-library/react'
import userEvent from '@testing-library/user-event'