@tsed/cli-plugin-jest 5.0.2 → 5.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tsed/cli-plugin-jest",
3
- "version": "5.0.2",
3
+ "version": "5.0.3",
4
4
  "description": "Ts.ED CLI plugin. Add Jest support",
5
5
  "source": "./src/index.ts",
6
6
  "main": "./lib/cjs/index.js",
@@ -20,11 +20,11 @@
20
20
  "test": "cross-env NODE_ENV=test yarn jest --max-workers=2 --passWithNoTests && jest-coverage-thresholds-bumper"
21
21
  },
22
22
  "devDependencies": {
23
- "@tsed/cli": "5.0.2",
24
- "@tsed/cli-core": "5.0.2",
25
- "@tsed/eslint": "5.0.2",
26
- "@tsed/jest-config": "5.0.2",
27
- "@tsed/typescript": "5.0.2",
23
+ "@tsed/cli": "5.0.3",
24
+ "@tsed/cli-core": "5.0.3",
25
+ "@tsed/eslint": "5.0.3",
26
+ "@tsed/jest-config": "5.0.3",
27
+ "@tsed/typescript": "5.0.3",
28
28
  "cross-env": "7.0.3",
29
29
  "eslint": "8.22.0",
30
30
  "jest": "29.5.0"
@@ -4,20 +4,15 @@ import { {{symbolName}} } from "./{{symbolPathBasename}}";
4
4
  import { Server } from "{{relativeSrcPath}}/Server";
5
5
 
6
6
  describe("{{symbolName}}", () => {
7
- let request: SuperTest.Agent;
8
-
9
7
  beforeEach(PlatformTest.bootstrap(Server, {
10
8
  mount: {
11
9
  "/": [{{symbolName}}]
12
10
  }
13
11
  }));
14
- beforeEach(() => {
15
- request = SuperTest(PlatformTest.callback());
16
- });
17
-
18
12
  afterEach(PlatformTest.reset);
19
13
 
20
14
  it("should call GET {{route}}", async () => {
15
+ const request = SuperTest(PlatformTest.callback());
21
16
  const response = await request.get("{{route}}").expect(200);
22
17
 
23
18
  expect(response.text).toEqual("hello");
@@ -3,16 +3,11 @@ import SuperTest from "supertest";
3
3
  import { {{symbolName}} } from "./{{symbolPathBasename}}";
4
4
 
5
5
  describe("{{symbolName}}", () => {
6
- let request: SuperTest.SuperTest<SuperTest.Test>;
7
-
8
6
  beforeEach(PlatformTest.bootstrap({{symbolName}}));
9
- beforeEach(() => {
10
- request = SuperTest(PlatformTest.callback());
11
- });
12
-
13
7
  afterEach(PlatformTest.reset);
14
8
 
15
9
  it("should call GET {{route}}", async () => {
10
+ const request = SuperTest(PlatformTest.callback());
16
11
  const response = await request.get("{{route}}").expect(404);
17
12
 
18
13
  expect(response.body).toEqual({