Skip to content

Commit

Permalink
add test for js browser
Browse files Browse the repository at this point in the history
  • Loading branch information
Lms24 committed Oct 17, 2024
1 parent f9e5240 commit 011f05c
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions api-node/test/sdks.e2e-spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -116,5 +116,23 @@ describe('SdksController (e2e)', () => {
expect(latest).toEqual(pythonApiData.latest);
});
});

it('Javascript Browser', async () => {
const sdkId = 'sentry.javascript.browser';

const pythonApiResponse = await fetch(
`${PYTHON_API_URL}/sdks/${sdkId}/versions`,
);
const pythonApiData = await pythonApiResponse.json();

return request(app.getHttpServer())
.get(`/sdks/${sdkId}/versions`)
.expect((r) => {
expect(r.status).toEqual(200);
const { versions, latest } = r.body;
expect(versions.sort()).toEqual(pythonApiData.versions.sort());
expect(latest).toEqual(pythonApiData.latest);
});
});
});
});

0 comments on commit 011f05c

Please sign in to comment.