@types/artillery 1.7.5 → 2.0.26
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.
- artillery/README.md +3 -15
- artillery/package.json +5 -23
- artillery/index.d.ts +0 -161
artillery/README.md
CHANGED
|
@@ -1,15 +1,3 @@
|
|
|
1
|
-
#
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
# Summary
|
|
5
|
-
This package contains type definitions for artillery (https://github.com/artilleryio/artillery).
|
|
6
|
-
|
|
7
|
-
# Details
|
|
8
|
-
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/artillery.
|
|
9
|
-
|
|
10
|
-
### Additional Details
|
|
11
|
-
* Last updated: Fri, 24 Oct 2025 04:02:41 GMT
|
|
12
|
-
* Dependencies: [@types/node](https://npmjs.com/package/@types/node), [@types/tough-cookie](https://npmjs.com/package/@types/tough-cookie), [got](https://npmjs.com/package/got)
|
|
13
|
-
|
|
14
|
-
# Credits
|
|
15
|
-
These definitions were written by [BendingBender](https://github.com/BendingBender).
|
|
1
|
+
This is a stub types definition for @types/artillery (https://github.com/artilleryio/artillery#readme).
|
|
2
|
+
|
|
3
|
+
artillery provides its own type definitions, so you don't need @types/artillery installed!
|
artillery/package.json
CHANGED
|
@@ -1,30 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@types/artillery",
|
|
3
|
-
"version": "
|
|
4
|
-
"description": "TypeScript definitions for artillery",
|
|
5
|
-
"homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/artillery",
|
|
6
|
-
"license": "MIT",
|
|
7
|
-
"contributors": [
|
|
8
|
-
{
|
|
9
|
-
"name": "BendingBender",
|
|
10
|
-
"githubUsername": "BendingBender",
|
|
11
|
-
"url": "https://github.com/BendingBender"
|
|
12
|
-
}
|
|
13
|
-
],
|
|
3
|
+
"version": "2.0.26",
|
|
4
|
+
"description": "Stub TypeScript definitions entry for artillery, which provides its own types definitions",
|
|
14
5
|
"main": "",
|
|
15
|
-
"types": "index.d.ts",
|
|
16
|
-
"repository": {
|
|
17
|
-
"type": "git",
|
|
18
|
-
"url": "https://github.com/DefinitelyTyped/DefinitelyTyped.git",
|
|
19
|
-
"directory": "types/artillery"
|
|
20
|
-
},
|
|
21
6
|
"scripts": {},
|
|
7
|
+
"license": "MIT",
|
|
22
8
|
"dependencies": {
|
|
23
|
-
"
|
|
24
|
-
"@types/tough-cookie": "*",
|
|
25
|
-
"got": "^11.8.5"
|
|
9
|
+
"artillery": "*"
|
|
26
10
|
},
|
|
27
|
-
"
|
|
28
|
-
"typesPublisherContentHash": "5096d0ec8912beacba8a2400e492617a461b993d6c6d6966efe62340a86ef279",
|
|
29
|
-
"typeScriptVersion": "5.2"
|
|
11
|
+
"deprecated": "This is a stub types definition. artillery provides its own type definitions, so you do not need this installed."
|
|
30
12
|
}
|
artillery/index.d.ts
DELETED
|
@@ -1,161 +0,0 @@
|
|
|
1
|
-
/// <reference types="node" />
|
|
2
|
-
|
|
3
|
-
import { OptionsOfJSONResponseBody, OptionsOfTextResponseBody, OptionsOfUnknownResponseBody, Response } from "got";
|
|
4
|
-
import events = require("node:events");
|
|
5
|
-
import { CookieJar } from "tough-cookie";
|
|
6
|
-
|
|
7
|
-
export type ActionFn<
|
|
8
|
-
TContextVars extends Record<string, unknown> = Record<string, unknown>,
|
|
9
|
-
TContextFuncs extends Record<string, (...args: any[]) => any> = Record<string, (...args: any[]) => any>,
|
|
10
|
-
> = (context: ScenarioContext<TContextVars, TContextFuncs>, ee: EventEmitter, next: Next) => void;
|
|
11
|
-
|
|
12
|
-
export type BeforeScenarioFn<
|
|
13
|
-
TContextVars extends Record<string, unknown> = Record<string, unknown>,
|
|
14
|
-
TContextFuncs extends Record<string, (...args: any[]) => any> = Record<string, (...args: any[]) => any>,
|
|
15
|
-
> = ActionFn<TContextVars, TContextFuncs>;
|
|
16
|
-
|
|
17
|
-
export type AfterScenarioFn<
|
|
18
|
-
TContextVars extends Record<string, unknown> = Record<string, unknown>,
|
|
19
|
-
TContextFuncs extends Record<string, (...args: any[]) => any> = Record<string, (...args: any[]) => any>,
|
|
20
|
-
> = ActionFn<TContextVars, TContextFuncs>;
|
|
21
|
-
|
|
22
|
-
export type BeforeRequestFn<
|
|
23
|
-
TContextVars extends Record<string, unknown> = Record<string, unknown>,
|
|
24
|
-
TContextFuncs extends Record<string, (...args: any[]) => any> = Record<string, (...args: any[]) => any>,
|
|
25
|
-
> = (
|
|
26
|
-
requestParams: RequestParams,
|
|
27
|
-
context: ScenarioContext<TContextVars, TContextFuncs>,
|
|
28
|
-
ee: EventEmitter,
|
|
29
|
-
next: Next,
|
|
30
|
-
) => void;
|
|
31
|
-
|
|
32
|
-
export type AfterResponseFn<
|
|
33
|
-
TContextVars extends Record<string, unknown> = Record<string, unknown>,
|
|
34
|
-
TContextFuncs extends Record<string, (...args: any[]) => any> = Record<string, (...args: any[]) => any>,
|
|
35
|
-
> = (
|
|
36
|
-
requestConfig:
|
|
37
|
-
& OptionsOfTextResponseBody
|
|
38
|
-
& OptionsOfJSONResponseBody
|
|
39
|
-
& OptionsOfUnknownResponseBody
|
|
40
|
-
& Record<string, unknown>,
|
|
41
|
-
response: Response,
|
|
42
|
-
context: ScenarioContext<TContextVars, TContextFuncs>,
|
|
43
|
-
ee: EventEmitter,
|
|
44
|
-
next: Next,
|
|
45
|
-
) => void;
|
|
46
|
-
|
|
47
|
-
export interface ScenarioContext<
|
|
48
|
-
TContextVars extends Record<string, unknown> = Record<string, unknown>,
|
|
49
|
-
TContextFuncs extends Record<string, (...args: any[]) => any> = Record<string, (...args: any[]) => any>,
|
|
50
|
-
> {
|
|
51
|
-
vars: TContextVars & ContextVars;
|
|
52
|
-
funcs: TContextFuncs & ContextFuncs;
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
export interface ContextVars {
|
|
56
|
-
target: string | undefined;
|
|
57
|
-
$environment: string | undefined;
|
|
58
|
-
$processEnvironment: Record<string, string>;
|
|
59
|
-
$uuid: string;
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
export interface ContextFuncs {
|
|
63
|
-
$randomNumber(max?: number): number;
|
|
64
|
-
// tslint:disable-next-line:unified-signatures
|
|
65
|
-
$randomNumber(min: number, max: number): number;
|
|
66
|
-
$randomString(length?: number): string;
|
|
67
|
-
$template<T>(input: T): T;
|
|
68
|
-
}
|
|
69
|
-
export type Next = (err?: Error) => void;
|
|
70
|
-
export interface EventEmitter extends events.EventEmitter {
|
|
71
|
-
addListener(
|
|
72
|
-
eventName: "counter" | "histogram" | "customStat",
|
|
73
|
-
listener: (name: string, value: number) => void,
|
|
74
|
-
): this;
|
|
75
|
-
addListener(eventName: "started" | "request", listener: () => void): this;
|
|
76
|
-
addListener(eventName: "error", listener: (error: unknown) => void): this;
|
|
77
|
-
addListener(eventName: "match", listener: (success: boolean, match: Match) => void): this;
|
|
78
|
-
addListener(eventName: "response", listener: (delta: number, code: number, uid: string) => void): this;
|
|
79
|
-
addListener(eventName: string | symbol, listener: (...args: unknown[]) => void): this;
|
|
80
|
-
on(eventName: "counter" | "histogram" | "customStat", listener: (name: string, value: number) => void): this;
|
|
81
|
-
on(eventName: "started" | "request", listener: () => void): this;
|
|
82
|
-
on(eventName: "error", listener: (error: unknown) => void): this;
|
|
83
|
-
on(eventName: "match", listener: (success: boolean, match: Match) => void): this;
|
|
84
|
-
on(eventName: "response", listener: (delta: number, code: number, uid: string) => void): this;
|
|
85
|
-
on(eventName: string | symbol, listener: (...args: unknown[]) => void): this;
|
|
86
|
-
once(eventName: "counter" | "histogram" | "customStat", listener: (name: string, value: number) => void): this;
|
|
87
|
-
once(eventName: "started" | "request", listener: () => void): this;
|
|
88
|
-
once(eventName: "error", listener: (error: unknown) => void): this;
|
|
89
|
-
once(eventName: "match", listener: (success: boolean, match: Match) => void): this;
|
|
90
|
-
once(eventName: "response", listener: (delta: number, code: number, uid: string) => void): this;
|
|
91
|
-
once(eventName: string | symbol, listener: (...args: unknown[]) => void): this;
|
|
92
|
-
removeListener(
|
|
93
|
-
eventName: "counter" | "histogram" | "customStat",
|
|
94
|
-
listener: (name: string, value: number) => void,
|
|
95
|
-
): this;
|
|
96
|
-
removeListener(eventName: "started" | "request", listener: () => void): this;
|
|
97
|
-
removeListener(eventName: "error", listener: (error: unknown) => void): this;
|
|
98
|
-
removeListener(eventName: "match", listener: (success: boolean, match: Match) => void): this;
|
|
99
|
-
removeListener(eventName: "response", listener: (delta: number, code: number, uid: string) => void): this;
|
|
100
|
-
removeListener(eventName: string | symbol, listener: (...args: unknown[]) => void): this;
|
|
101
|
-
off(eventName: "counter" | "histogram" | "customStat", listener: (name: string, value: number) => void): this;
|
|
102
|
-
off(eventName: "started" | "request", listener: () => void): this;
|
|
103
|
-
off(eventName: "error", listener: (error: unknown) => void): this;
|
|
104
|
-
off(eventName: "match", listener: (success: boolean, match: Match) => void): this;
|
|
105
|
-
off(eventName: "response", listener: (delta: number, code: number, uid: string) => void): this;
|
|
106
|
-
off(eventName: string | symbol, listener: (...args: unknown[]) => void): this;
|
|
107
|
-
emit(eventName: "counter" | "histogram" | "customStat", name: string, value: number): boolean;
|
|
108
|
-
emit(eventName: "started" | "request"): boolean;
|
|
109
|
-
emit(eventName: "error", error: unknown): boolean;
|
|
110
|
-
emit(eventName: "match", success: boolean, match: Match): boolean;
|
|
111
|
-
emit(eventName: "response", delta: number, code: number, uid: string): boolean;
|
|
112
|
-
emit(eventName: string | symbol, ...args: unknown[]): boolean;
|
|
113
|
-
prependListener(
|
|
114
|
-
eventName: "counter" | "histogram" | "customStat",
|
|
115
|
-
listener: (name: string, value: number) => void,
|
|
116
|
-
): this;
|
|
117
|
-
prependListener(eventName: "started" | "request", listener: () => void): this;
|
|
118
|
-
prependListener(eventName: "error", listener: (error: unknown) => void): this;
|
|
119
|
-
prependListener(eventName: "match", listener: (success: boolean, match: Match) => void): this;
|
|
120
|
-
prependListener(eventName: "response", listener: (delta: number, code: number, uid: string) => void): this;
|
|
121
|
-
prependListener(eventName: string | symbol, listener: (...args: unknown[]) => void): this;
|
|
122
|
-
prependOnceListener(
|
|
123
|
-
eventName: "counter" | "histogram" | "customStat",
|
|
124
|
-
listener: (name: string, value: number) => void,
|
|
125
|
-
): this;
|
|
126
|
-
prependOnceListener(eventName: "started" | "request", listener: () => void): this;
|
|
127
|
-
prependOnceListener(eventName: "error", listener: (error: unknown) => void): this;
|
|
128
|
-
prependOnceListener(eventName: "match", listener: (success: boolean, match: Match) => void): this;
|
|
129
|
-
prependOnceListener(eventName: "response", listener: (delta: number, code: number, uid: string) => void): this;
|
|
130
|
-
prependOnceListener(eventName: string | symbol, listener: (...args: unknown[]) => void): this;
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
export interface Match {
|
|
134
|
-
expected: string;
|
|
135
|
-
got?: string;
|
|
136
|
-
expression: string;
|
|
137
|
-
strict?: boolean;
|
|
138
|
-
}
|
|
139
|
-
|
|
140
|
-
export interface RequestParams {
|
|
141
|
-
[key: string]: unknown;
|
|
142
|
-
|
|
143
|
-
url?: string;
|
|
144
|
-
uri?: string;
|
|
145
|
-
method: string;
|
|
146
|
-
headers: Record<string, string>;
|
|
147
|
-
timeout: number;
|
|
148
|
-
json?: Record<string | number, unknown>;
|
|
149
|
-
form?: Record<string | number, unknown>;
|
|
150
|
-
formData?: Record<string | number, unknown>;
|
|
151
|
-
cookieJar?: CookieJar;
|
|
152
|
-
https?: Record<string, unknown>;
|
|
153
|
-
body?: unknown;
|
|
154
|
-
name?: string;
|
|
155
|
-
followRedirect?: boolean;
|
|
156
|
-
followAllRedirects?: boolean;
|
|
157
|
-
auth?: {
|
|
158
|
-
user: string;
|
|
159
|
-
pass: string;
|
|
160
|
-
};
|
|
161
|
-
}
|