Skip to content

Commit d7c3668

Browse files
committed
lint fix
1 parent c80eb26 commit d7c3668

2 files changed

Lines changed: 29 additions & 20 deletions

File tree

src/views/schedule-details/schedule-details-backfills-table/__tests__/schedule-details-backfills-table.test.tsx

Lines changed: 22 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -22,16 +22,18 @@ const mockBackfills: BackfillInfo[] = [
2222
},
2323
];
2424

25-
jest.mock('next/link', () =>
26-
function MockLink({
27-
href,
28-
children,
29-
}: {
30-
href: string;
31-
children: React.ReactNode;
32-
}) {
33-
return <a href={href}>{children}</a>;
34-
}
25+
jest.mock(
26+
'next/link',
27+
() =>
28+
function MockLink({
29+
href,
30+
children,
31+
}: {
32+
href: string;
33+
children: React.ReactNode;
34+
}) {
35+
return <a href={href}>{children}</a>;
36+
}
3537
);
3638

3739
describe(ScheduleDetailsBackfillsTable.name, () => {
@@ -71,21 +73,23 @@ describe(ScheduleDetailsBackfillsTable.name, () => {
7173

7274
it('renders nothing when no backfills', () => {
7375
setup({ backfills: [] });
74-
expect(
75-
screen.queryByText(/ongoing backfills/i)
76-
).not.toBeInTheDocument();
76+
expect(screen.queryByText(/ongoing backfills/i)).not.toBeInTheDocument();
7777
expect(screen.queryByText('Backfill ID')).not.toBeInTheDocument();
7878
});
7979

8080
it('collapses content when toggle button is clicked', async () => {
8181
const { user } = setup({});
82-
expect(screen.getByRole('link', { name: 'backfill-abc-123' })).toBeInTheDocument();
82+
expect(
83+
screen.getByRole('link', { name: 'backfill-abc-123' })
84+
).toBeInTheDocument();
8385

8486
await user.click(
8587
screen.getByRole('button', { name: /collapse ongoing backfills/i })
8688
);
8789

88-
expect(screen.queryByRole('link', { name: 'backfill-abc-123' })).not.toBeInTheDocument();
90+
expect(
91+
screen.queryByRole('link', { name: 'backfill-abc-123' })
92+
).not.toBeInTheDocument();
8993
});
9094

9195
it('expands content again after collapsing', async () => {
@@ -98,7 +102,9 @@ describe(ScheduleDetailsBackfillsTable.name, () => {
98102
screen.getByRole('button', { name: /expand ongoing backfills/i })
99103
);
100104

101-
expect(screen.getByRole('link', { name: 'backfill-abc-123' })).toBeInTheDocument();
105+
expect(
106+
screen.getByRole('link', { name: 'backfill-abc-123' })
107+
).toBeInTheDocument();
102108
});
103109
});
104110

src/views/schedule-details/schedule-details-backfills-table/schedule-details-backfills-table.styles.ts

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,13 @@ import { type TableOverrides } from 'baseui/table-semantic';
33
import { type StyleObject } from 'styletron-react';
44

55
export const styled = {
6-
Section: createStyled('section', (): StyleObject => ({
7-
display: 'flex',
8-
flexDirection: 'column',
9-
})),
6+
Section: createStyled(
7+
'section',
8+
(): StyleObject => ({
9+
display: 'flex',
10+
flexDirection: 'column',
11+
})
12+
),
1013
TableContainer: createStyled(
1114
'div',
1215
({ $theme }: { $theme: Theme }): StyleObject => ({

0 commit comments

Comments
 (0)