@loopback/testlab 4.0.0 → 4.0.1

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/dist/client.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  /// <reference types="node" />
2
2
  import http from 'http';
3
- import supertest = require('supertest');
3
+ import supertest from 'supertest';
4
4
  export { supertest };
5
5
  export declare type Client = supertest.SuperTest<supertest.Test>;
6
6
  /**
package/dist/client.js CHANGED
@@ -10,8 +10,8 @@ const tslib_1 = require("tslib");
10
10
  * HTTP client utilities
11
11
  */
12
12
  const http_1 = (0, tslib_1.__importDefault)(require("http"));
13
- const supertest = require("supertest");
14
- exports.supertest = supertest;
13
+ const supertest_1 = (0, tslib_1.__importDefault)(require("supertest"));
14
+ exports.supertest = supertest_1.default;
15
15
  /**
16
16
  * Create a SuperTest client connected to an HTTP server listening
17
17
  * on an ephemeral port and calling `handler` to handle incoming requests.
@@ -19,7 +19,7 @@ exports.supertest = supertest;
19
19
  */
20
20
  function createClientForHandler(handler) {
21
21
  const server = http_1.default.createServer(handler);
22
- return supertest(server);
22
+ return (0, supertest_1.default)(server);
23
23
  }
24
24
  exports.createClientForHandler = createClientForHandler;
25
25
  /**
@@ -34,7 +34,7 @@ function createRestAppClient(app) {
34
34
  if (!url) {
35
35
  throw new Error(`Cannot create client for ${app.constructor.name}, it is not listening.`);
36
36
  }
37
- return supertest(url);
37
+ return (0, supertest_1.default)(url);
38
38
  }
39
39
  exports.createRestAppClient = createRestAppClient;
40
40
  //# sourceMappingURL=client.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"client.js","sourceRoot":"","sources":["../src/client.ts"],"names":[],"mappings":";AAAA,sDAAsD;AACtD,iCAAiC;AACjC,+CAA+C;AAC/C,gEAAgE;;;;AAEhE;;GAEG;AAEH,6DAAwB;AACxB,uCAAwC;AAEhC,8BAAS;AAIjB;;;;GAIG;AACH,SAAgB,sBAAsB,CACpC,OAAsE;IAEtE,MAAM,MA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 @@
1
1
  {
2
2
  "name": "@loopback/testlab",
3
3
  "description": "A collection of test utilities we use to write LoopBack tests.",
4
- "version": "4.0.0",
4
+ "version": "4.0.1",
5
5
  "license": "MIT",
6
6
  "main": "dist/index.js",
7
7
  "types": "dist/index.d.ts",
@@ -40,18 +40,18 @@
40
40
  "@types/shot": "^4.0.1",
41
41
  "@types/sinon": "^10.0.6",
42
42
  "@types/supertest": "^2.0.11",
43
- "express": "^4.17.1",
43
+ "express": "^4.17.2",
44
44
  "fs-extra": "^10.0.0",
45
45
  "oas-validator": "^5.0.8",
46
46
  "should": "^13.2.3",
47
47
  "sinon": "^11.1.2",
48
- "supertest": "^6.1.6",
48
+ "supertest": "^6.2.0",
49
49
  "tslib": "^2.3.1"
50
50
  },
51
51
  "devDependencies": {
52
- "@loopback/build": "^8.0.0",
53
- "@loopback/eslint-config": "^12.0.0",
52
+ "@loopback/build": "^8.0.1",
53
+ "@loopback/eslint-config": "^12.0.1",
54
54
  "@types/node": "^10.17.60"
55
55
  },
56
- "gitHead": "00a62f630c19341ce399cec3a45563b1ead6e3b8"
56
+ "gitHead": "4a8886403cd9cb3ae529cb69712f077623cba2c2"
57
57
  }
package/src/client.ts CHANGED
@@ -8,7 +8,7 @@
8
8
  */
9
9
 
10
10
  import http from 'http';
11
- import supertest = require('supertest');
11
+ import supertest from 'supertest';
12
12
 
13
13
  export {supertest};
14
14