Skip to content

Commit d44a244

Browse files
committed
test(docs): give the catalog compile tests room for the compiler's cold start
1 parent 26e2d7d commit d44a244

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

‎apps/docs/lib/content/compile.test.ts‎

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,9 @@ import type { DocsPage } from '@/lib/content/types'
99
import { getIntegrationSeo } from '@/lib/integrations/seo'
1010
import { pageSearchChunks } from '@/lib/search/chunks'
1111

12+
/** The first compile loads MDX and builds the whole catalog, which exceeds the default 5s on a busy runner. */
13+
const COMPILE_TIMEOUT_MS = 30_000
14+
1215
async function compilePage(url: string, body: string, integration?: DocsPage['integration']) {
1316
const faqs = getIntegrationSeo({ url, integration })?.faqs ?? []
1417
const result = await compileDocument(`${url.slice(1)}.mdx`, body, '', faqs)
@@ -39,7 +42,7 @@ Reconnect a revoked connection.
3942
<IntegrationCatalog />
4043
`
4144

42-
describe('integrations index catalog', () => {
45+
describe('integrations index catalog', { timeout: COMPILE_TIMEOUT_MS }, () => {
4346
it('is in the headings, the Markdown copy and the link checks', async () => {
4447
const { result } = await compilePage('/integrations', INDEX_BODY)
4548

@@ -62,7 +65,7 @@ describe('integrations index catalog', () => {
6265
})
6366
})
6467

65-
describe('integration page FAQ', () => {
68+
describe('integration page FAQ', { timeout: COMPILE_TIMEOUT_MS }, () => {
6669
it('reaches the Markdown copy and search as its own section', async () => {
6770
const { result, page } = await compilePage('/integrations/slack', 'Send Slack messages.\n', {
6871
type: 'slack_v2',

0 commit comments

Comments
 (0)