lint fixes

This commit is contained in:
Aaro Koivukangas
2024-09-12 13:36:26 +03:00
committed by Aaro Koivukangas
parent 227d4fb0ec
commit a92a17a1d7
3 changed files with 3 additions and 6 deletions
+1 -2
View File
@@ -1,4 +1,3 @@
/* eslint-disable @typescript-eslint/no-floating-promises */
import { beforeEach, describe, it, expect } from '@jest/globals'
import { LocalityDetailsType, SpeciesDetailsType } from '../../../../frontend/src/backendTypes'
import { LogRow } from '../../services/write/writeOperations/types'
@@ -36,7 +35,7 @@ describe('Creating new species works', () => {
if (!localityFound) throw new Error('Locality was not found in now_ls')
const speciesResult = await send<LocalityDetailsType>(`locality/24750`, 'GET')
const update = speciesResult.body.now_lau.find(lau => lau.lid === 24750 && lau.lau_comment === 'species test')
if(!update) throw new Error('Update not found')
if (!update) throw new Error('Update not found')
const logRows = update.updates
const expectedLogRows: Partial<LogRow>[] = [
{
@@ -1,4 +1,3 @@
/* eslint-disable @typescript-eslint/no-floating-promises */
import { beforeEach, describe, it, expect } from '@jest/globals'
import { login, send } from '../utils'
+2 -3
View File
@@ -1,4 +1,3 @@
/* eslint-disable @typescript-eslint/no-floating-promises */
import { beforeEach, describe, it, expect } from '@jest/globals'
import { EditMetaData, SpeciesDetailsType } from '../../../../frontend/src/backendTypes'
import { LogRow } from '../../services/write/writeOperations/types'
@@ -27,8 +26,8 @@ describe('Updating species works', () => {
})
it('Added locality species is found', () => {
editedSpeciesResult!.now_ls.find(ls => ls.species_id === editedSpecies.species_id && ls.lid === 20920) //'Added locality species not found'
expect(!!editedSpeciesResult).toEqual(true)
editedSpeciesResult!.now_ls.find(ls => ls.species_id === editedSpecies.species_id && ls.lid === 20920) //'Added locality species not found'
expect(!!editedSpeciesResult).toEqual(true)
})
it('Locality species include correct amount of entries', () => {