We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent e9da96e commit 67a522cCopy full SHA for 67a522c
1 file changed
app/api/streak/route.test.ts
@@ -87,6 +87,18 @@ describe('GET /api/streak', () => {
87
vi.mocked(getSecondsUntilMidnightInTimezone).mockReturnValue(7200);
88
});
89
90
+ it('falls back to the default isometric view when an invalid view is provided', async () => {
91
+ const request = new Request('http://localhost:3000/api/streak?user=octocat&view=invalid');
92
+
93
+ const response = await GET(request);
94
95
+ expect(response.status).toBe(200);
96
97
+ const body = await response.text();
98
99
+ expect(body).toContain('@keyframes grow-up');
100
+ });
101
102
describe('parameter validation', () => {
103
it('returns 400 when the user parameter is missing', async () => {
104
const response = await GET(makeRequest());
0 commit comments