Skip to content

Commit ae6bb33

Browse files
DIYgodclaude
andcommitted
fix(test): increase timeout for Worker integration tests
Worker tests need more time in CI environments. Increase individual test timeouts from default 10s to 30s for each test case. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <[email protected]>
1 parent 8d0a53a commit ae6bb33

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

lib/worker.worker.test.ts

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -27,17 +27,17 @@ describe('Worker Integration Tests', () => {
2727
expect(text).toContain('<?xml');
2828
expect(text).toContain('<rss');
2929
expect(text).toContain('Test 1');
30-
});
30+
}, 30000);
3131

3232
it('should respond to / with welcome page', async () => {
3333
const response = await worker.fetch('/');
3434
expect(response.status).toBe(200);
35-
});
35+
}, 30000);
3636

3737
it('should return error for unknown routes', async () => {
3838
const response = await worker.fetch('/nonexistent/route/12345');
3939
expect(response.status).toBeGreaterThanOrEqual(400);
40-
});
40+
}, 30000);
4141
});
4242

4343
describe('Test Route Variations', () => {
@@ -46,32 +46,32 @@ describe('Worker Integration Tests', () => {
4646
expect(response.status).toBe(200);
4747
const text = await response.text();
4848
expect(text).toContain('Filter Title');
49-
});
49+
}, 30000);
5050

5151
it('should handle /test/json route', async () => {
5252
const response = await worker.fetch('/test/json');
5353
expect(response.status).toBe(200);
5454
const text = await response.text();
5555
expect(text).toContain('Title0');
56-
});
56+
}, 30000);
5757

5858
it('should handle /test/cache route', async () => {
5959
const response = await worker.fetch('/test/cache');
6060
expect(response.status).toBe(200);
6161
const text = await response.text();
6262
expect(text).toContain('Cache Title');
63-
});
63+
}, 30000);
6464
});
6565

6666
describe('Error Handling', () => {
6767
it('should handle /test/error route', async () => {
6868
const response = await worker.fetch('/test/error');
6969
expect(response.status).toBeGreaterThanOrEqual(400);
70-
});
70+
}, 30000);
7171

7272
it('should handle /test/httperror route', async () => {
7373
const response = await worker.fetch('/test/httperror');
7474
expect(response.status).toBeGreaterThanOrEqual(400);
75-
});
75+
}, 30000);
7676
});
7777
});

0 commit comments

Comments
 (0)