mirror of
https://github.com/mauriceboe/TREK.git
synced 2026-06-21 14:21:46 +00:00
chore: apply prettier on the entire project
This commit is contained in:
@@ -1,12 +1,12 @@
|
||||
import { formatAssignmentWithPlace } from '../../../src/services/queryHelpers';
|
||||
import type { AssignmentRow, Tag, Participant } from '../../../src/types';
|
||||
|
||||
import { describe, it, expect, vi } from 'vitest';
|
||||
|
||||
vi.mock('../../../src/db/database', () => ({
|
||||
db: { prepare: () => ({ all: () => [], get: vi.fn() }) },
|
||||
}));
|
||||
|
||||
import { formatAssignmentWithPlace } from '../../../src/services/queryHelpers';
|
||||
import type { AssignmentRow, Tag, Participant } from '../../../src/types';
|
||||
|
||||
function makeRow(overrides: Partial<AssignmentRow> = {}): AssignmentRow {
|
||||
return {
|
||||
id: 1,
|
||||
@@ -39,13 +39,9 @@ function makeRow(overrides: Partial<AssignmentRow> = {}): AssignmentRow {
|
||||
} as AssignmentRow;
|
||||
}
|
||||
|
||||
const sampleTags: Partial<Tag>[] = [
|
||||
{ id: 1, name: 'Must-see', color: '#ef4444' },
|
||||
];
|
||||
const sampleTags: Partial<Tag>[] = [{ id: 1, name: 'Must-see', color: '#ef4444' }];
|
||||
|
||||
const sampleParticipants: Participant[] = [
|
||||
{ user_id: 42, username: 'alice', avatar: null },
|
||||
];
|
||||
const sampleParticipants: Participant[] = [{ user_id: 42, username: 'alice', avatar: null }];
|
||||
|
||||
describe('formatAssignmentWithPlace', () => {
|
||||
it('nests place fields correctly from flat row', () => {
|
||||
|
||||
Reference in New Issue
Block a user