@gatling.io/core 3.12.0 → 3.13.2
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,20 +1,20 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gatling.io/core",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.13.2",
|
|
4
4
|
"license": "Apache-2.0",
|
|
5
5
|
"main": "target/index.js",
|
|
6
6
|
"types": "target/index.d.ts",
|
|
7
7
|
"dependencies": {
|
|
8
|
-
"@gatling.io/jvm-types": "3.
|
|
8
|
+
"@gatling.io/jvm-types": "3.13.2"
|
|
9
9
|
},
|
|
10
10
|
"devDependencies": {
|
|
11
|
-
"@types/jest": "29.5.
|
|
11
|
+
"@types/jest": "29.5.14",
|
|
12
12
|
"jest": "29.7.0",
|
|
13
13
|
"prettier": "3.3.3",
|
|
14
14
|
"rimraf": "6.0.1",
|
|
15
15
|
"ts-jest": "29.2.5",
|
|
16
16
|
"ts-node": "10.9.2",
|
|
17
|
-
"typescript": "5.
|
|
17
|
+
"typescript": "5.6.3"
|
|
18
18
|
},
|
|
19
19
|
"scripts": {
|
|
20
20
|
"clean": "rimraf target",
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
interface Resources {
|
|
2
|
+
readResourceAsBytes(filePath: string): number[];
|
|
3
|
+
readResourceAsString(filePath: string, charset: string): string;
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
const Resources = Java.type<Resources>("io.gatling.js.Resources");
|
|
7
|
+
|
|
8
|
+
export const readResourceAsBytes = (filePath: string): number[] => Resources.readResourceAsBytes(filePath);
|
|
9
|
+
|
|
10
|
+
export const readResourceAsString = (filePath: string, charset?: string): string =>
|
|
11
|
+
Resources.readResourceAsString(filePath, charset !== undefined ? charset : "utf-8");
|
package/src/index.ts
CHANGED
|
@@ -11,7 +11,9 @@ import { ProtocolBuilder } from "./protocol";
|
|
|
11
11
|
import { ThrottleStep } from "./throttling";
|
|
12
12
|
|
|
13
13
|
// FIXME no export *
|
|
14
|
+
export { asJava } from "./gatlingJvm/collections";
|
|
14
15
|
export { asByteArray, asByteArrayFunction } from "./gatlingJvm/byteArrays";
|
|
16
|
+
export { readResourceAsBytes, readResourceAsString } from "./gatlingJvm/resources";
|
|
15
17
|
export * from "./utils/duration";
|
|
16
18
|
export * from "./assertions";
|
|
17
19
|
export * from "./body";
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.readResourceAsString = exports.readResourceAsBytes = void 0;
|
|
4
|
+
const Resources = Java.type("io.gatling.js.Resources");
|
|
5
|
+
const readResourceAsBytes = (filePath) => Resources.readResourceAsBytes(filePath);
|
|
6
|
+
exports.readResourceAsBytes = readResourceAsBytes;
|
|
7
|
+
const readResourceAsString = (filePath, charset) => Resources.readResourceAsString(filePath, charset !== undefined ? charset : "utf-8");
|
|
8
|
+
exports.readResourceAsString = readResourceAsString;
|
package/target/index.d.ts
CHANGED
|
@@ -7,7 +7,9 @@ import { Assertion } from "./assertions";
|
|
|
7
7
|
import { PopulationBuilder } from "./population";
|
|
8
8
|
import { ProtocolBuilder } from "./protocol";
|
|
9
9
|
import { ThrottleStep } from "./throttling";
|
|
10
|
+
export { asJava } from "./gatlingJvm/collections";
|
|
10
11
|
export { asByteArray, asByteArrayFunction } from "./gatlingJvm/byteArrays";
|
|
12
|
+
export { readResourceAsBytes, readResourceAsString } from "./gatlingJvm/resources";
|
|
11
13
|
export * from "./utils/duration";
|
|
12
14
|
export * from "./assertions";
|
|
13
15
|
export * from "./body";
|
package/target/index.js
CHANGED
|
@@ -14,15 +14,20 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
exports.simulation = exports.getEnvironmentVariable = exports.getOption = exports.getParameter = exports.GlobalStore = exports.asByteArrayFunction = exports.asByteArray = void 0;
|
|
17
|
+
exports.simulation = exports.getEnvironmentVariable = exports.getOption = exports.getParameter = exports.GlobalStore = exports.readResourceAsString = exports.readResourceAsBytes = exports.asByteArrayFunction = exports.asByteArray = exports.asJava = void 0;
|
|
18
18
|
require("@gatling.io/jvm-types");
|
|
19
19
|
const pauses_1 = require("./structure/pauses");
|
|
20
20
|
const duration_1 = require("./utils/duration");
|
|
21
21
|
const session_1 = require("./session");
|
|
22
22
|
// FIXME no export *
|
|
23
|
+
var collections_1 = require("./gatlingJvm/collections");
|
|
24
|
+
Object.defineProperty(exports, "asJava", { enumerable: true, get: function () { return collections_1.asJava; } });
|
|
23
25
|
var byteArrays_1 = require("./gatlingJvm/byteArrays");
|
|
24
26
|
Object.defineProperty(exports, "asByteArray", { enumerable: true, get: function () { return byteArrays_1.asByteArray; } });
|
|
25
27
|
Object.defineProperty(exports, "asByteArrayFunction", { enumerable: true, get: function () { return byteArrays_1.asByteArrayFunction; } });
|
|
28
|
+
var resources_1 = require("./gatlingJvm/resources");
|
|
29
|
+
Object.defineProperty(exports, "readResourceAsBytes", { enumerable: true, get: function () { return resources_1.readResourceAsBytes; } });
|
|
30
|
+
Object.defineProperty(exports, "readResourceAsString", { enumerable: true, get: function () { return resources_1.readResourceAsString; } });
|
|
26
31
|
__exportStar(require("./utils/duration"), exports);
|
|
27
32
|
__exportStar(require("./assertions"), exports);
|
|
28
33
|
__exportStar(require("./body"), exports);
|