Remove more ovbious ramda helper usages

This commit is contained in:
Alejandro Celaya
2023-11-01 10:07:50 +01:00
parent 8699eaca32
commit 7ba78fd919
8 changed files with 25 additions and 29 deletions

View File

@@ -1,6 +1,5 @@
import { screen } from '@testing-library/react';
import { fromPartial } from '@total-typescript/shoehorn';
import { values } from 'ramda';
import { MemoryRouter } from 'react-router-dom';
import type { ServersMap } from '../../src/servers/data';
import { ServersDropdown } from '../../src/servers/ServersDropdown';
@@ -28,7 +27,7 @@ describe('<ServersDropdown />', () => {
await user.click(screen.getByText('Servers'));
const items = screen.getAllByRole('menuitem');
expect(items).toHaveLength(values(fallbackServers).length + 1);
expect(items).toHaveLength(Object.values(fallbackServers).length + 1);
expect(items[0]).toHaveTextContent('foo');
expect(items[1]).toHaveTextContent('bar');
expect(items[2]).toHaveTextContent('baz');