mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-13 10:03:31 +01:00
style: cleanup tests and tsup configs
This commit is contained in:
@@ -2,7 +2,8 @@
|
||||
"root": true,
|
||||
"extends": "marine/prettier/node",
|
||||
"parserOptions": {
|
||||
"project": "./tsconfig.eslint.json"
|
||||
"project": "./tsconfig.eslint.json",
|
||||
"extraFileExtensions": [".mjs"]
|
||||
},
|
||||
"ignorePatterns": ["**/dist/*"],
|
||||
"env": {
|
||||
|
||||
@@ -58,7 +58,7 @@ test('simple GET', async () => {
|
||||
expect(headers['content-type']).toEqual(expect.stringMatching(/^application\/json/));
|
||||
// Ratelimit headers should be dropped
|
||||
expect(headers).not.toHaveProperty('x-ratelimit-limit');
|
||||
expect(res.statusCode).toBe(200);
|
||||
expect(res.statusCode).toEqual(200);
|
||||
expect(res.body).toStrictEqual({ test: true });
|
||||
});
|
||||
|
||||
@@ -78,6 +78,6 @@ test('failed request', async () => {
|
||||
const headers = res.headers as Record<string, string>;
|
||||
|
||||
expect(headers['content-type']).toEqual(expect.stringMatching(/^application\/json/));
|
||||
expect(res.statusCode).toBe(404);
|
||||
expect(res.statusCode).toEqual(404);
|
||||
expect(res.body).toStrictEqual({ code: 404, message: 'Not Found' });
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user