@testomatio/reporter 1.6.16 → 1.6.17-beta.1-tls-fix

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.
Files changed (50) hide show
  1. package/lib/adapter/codecept.d.ts +2 -0
  2. package/lib/adapter/cucumber/current.d.ts +14 -0
  3. package/lib/adapter/cucumber/legacy.d.ts +0 -0
  4. package/lib/adapter/cucumber.d.ts +2 -0
  5. package/lib/adapter/cypress-plugin/index.d.ts +2 -0
  6. package/lib/adapter/jasmine.d.ts +11 -0
  7. package/lib/adapter/jest.d.ts +13 -0
  8. package/lib/adapter/mocha.d.ts +2 -0
  9. package/lib/adapter/nightwatch.d.ts +4 -0
  10. package/lib/adapter/nightwatch.js +75 -0
  11. package/lib/adapter/playwright.d.ts +14 -0
  12. package/lib/adapter/vitest.d.ts +35 -0
  13. package/lib/adapter/webdriver.d.ts +24 -0
  14. package/lib/bin/cli.d.ts +2 -0
  15. package/lib/bin/reportXml.d.ts +2 -0
  16. package/lib/bin/startTest.d.ts +2 -0
  17. package/lib/bin/uploadArtifacts.d.ts +2 -0
  18. package/lib/client.d.ts +76 -0
  19. package/lib/config.d.ts +1 -0
  20. package/lib/constants.d.ts +25 -0
  21. package/lib/data-storage.d.ts +34 -0
  22. package/lib/junit-adapter/adapter.d.ts +9 -0
  23. package/lib/junit-adapter/csharp.d.ts +5 -0
  24. package/lib/junit-adapter/index.d.ts +3 -0
  25. package/lib/junit-adapter/java.d.ts +5 -0
  26. package/lib/junit-adapter/javascript.d.ts +4 -0
  27. package/lib/junit-adapter/python.d.ts +5 -0
  28. package/lib/junit-adapter/ruby.d.ts +4 -0
  29. package/lib/output.d.ts +11 -0
  30. package/lib/package.json +3 -0
  31. package/lib/pipe/bitbucket.d.ts +23 -0
  32. package/lib/pipe/csv.d.ts +47 -0
  33. package/lib/pipe/debug.d.ts +29 -0
  34. package/lib/pipe/github.d.ts +30 -0
  35. package/lib/pipe/gitlab.d.ts +23 -0
  36. package/lib/pipe/html.d.ts +35 -0
  37. package/lib/pipe/index.d.ts +1 -0
  38. package/lib/pipe/testomatio.d.ts +70 -0
  39. package/lib/pipe/testomatio.js +5 -0
  40. package/lib/reporter-functions.d.ts +34 -0
  41. package/lib/reporter.d.ts +232 -0
  42. package/lib/services/artifacts.d.ts +33 -0
  43. package/lib/services/index.d.ts +9 -0
  44. package/lib/services/key-values.d.ts +27 -0
  45. package/lib/services/logger.d.ts +64 -0
  46. package/lib/uploader.d.ts +60 -0
  47. package/lib/utils/pipe_utils.d.ts +41 -0
  48. package/lib/utils/utils.d.ts +45 -0
  49. package/lib/xmlReader.d.ts +92 -0
  50. package/package.json +1 -1
@@ -0,0 +1,70 @@
1
+ export default TestomatioPipe;
2
+ export type Pipe = import("../../types/types.js").Pipe;
3
+ export type TestData = import("../../types/types.js").TestData;
4
+ /**
5
+ * @typedef {import('../../types/types.js').Pipe} Pipe
6
+ * @typedef {import('../../types/types.js').TestData} TestData
7
+ * @class TestomatioPipe
8
+ * @implements {Pipe}
9
+ */
10
+ declare class TestomatioPipe implements Pipe {
11
+ constructor(params: any, store: any);
12
+ batch: {
13
+ isEnabled: any;
14
+ intervalFunction: any;
15
+ intervalTime: number;
16
+ tests: any[];
17
+ batchIndex: number;
18
+ numberOfTimesCalledWithoutTests: number;
19
+ };
20
+ retriesTimestamps: any[];
21
+ reportingCanceledDueToReqFailures: boolean;
22
+ notReportedTestsCount: number;
23
+ isEnabled: boolean;
24
+ url: any;
25
+ apiKey: any;
26
+ parallel: any;
27
+ store: any;
28
+ title: any;
29
+ sharedRun: boolean;
30
+ sharedRunTimeout: boolean;
31
+ groupTitle: any;
32
+ env: string;
33
+ label: string;
34
+ axios: import("axios").AxiosInstance;
35
+ proceed: string;
36
+ jiraId: string;
37
+ runId: any;
38
+ createNewTests: any;
39
+ hasUnmatchedTests: boolean;
40
+ requestFailures: number;
41
+ /**
42
+ * Asynchronously prepares and retrieves the Testomat.io test grepList based on the provided options.
43
+ * @param {Object} opts - The options for preparing the test grepList.
44
+ * @returns {Promise<string[]>} - An array containing the retrieved
45
+ * test grepList, or an empty array if no tests are found or the request is disabled.
46
+ * @throws {Error} - Throws an error if there was a problem while making the request.
47
+ */
48
+ prepareRun(opts: any): Promise<string[]>;
49
+ /**
50
+ * Creates a new run on Testomat.io
51
+ * @param {{isBatchEnabled?: boolean}} params
52
+ * @returns Promise<void>
53
+ */
54
+ createRun(params?: {
55
+ isBatchEnabled?: boolean;
56
+ }): Promise<void>;
57
+ runUrl: string;
58
+ runPublicUrl: any;
59
+ /**
60
+ * Adds a test to the batch uploader (or reports a single test if batch uploading is disabled)
61
+ */
62
+ addTest(data: any): void;
63
+ /**
64
+ * @param {import('../../types/types.js').RunData} params
65
+ * @returns
66
+ */
67
+ finishRun(params: import("../../types/types.js").RunData): Promise<void>;
68
+ toString(): string;
69
+ #private;
70
+ }
@@ -3,6 +3,7 @@ const chalk = require('chalk');
3
3
  // Retry interceptor function
4
4
  const axiosRetry = require('axios-retry');
5
5
  // Default axios instance
6
+ const https = require('https');
6
7
  const axios = require('axios');
7
8
  const JsonCycle = require('json-cycle');
8
9
 
@@ -57,6 +58,10 @@ class TestomatioPipe {
57
58
  // Create a new instance of axios with a custom config
58
59
  this.axios = axios.create({
59
60
  baseURL: `${this.url.trim()}`,
61
+ httpsAgent: new https.Agent({
62
+ rejectUnauthorized: true,
63
+ keepAlive: false // This is the key setting that forces fresh TLS sessions
64
+ }),
60
65
  timeout: AXIOS_TIMEOUT,
61
66
  proxy: proxy ? {
62
67
  host: proxy.hostname,
@@ -0,0 +1,34 @@
1
+ declare namespace _default {
2
+ export { saveArtifact as artifact };
3
+ export { logMessage as log };
4
+ export { addStep as step };
5
+ export { setKeyValue as keyValue };
6
+ }
7
+ export default _default;
8
+ /**
9
+ * Stores path to file as artifact and uploads it to the S3 storage
10
+ * @param {string | {path: string, type: string, name: string}} data - path to file or object with path, type and name
11
+ */
12
+ declare function saveArtifact(data: string | {
13
+ path: string;
14
+ type: string;
15
+ name: string;
16
+ }, context?: any): void;
17
+ /**
18
+ * Attach log message(s) to the test report
19
+ * @param string
20
+ */
21
+ declare function logMessage(...args: any[]): void;
22
+ /**
23
+ * Similar to "log" function but marks message in report as a step
24
+ * @param {string} message
25
+ */
26
+ declare function addStep(message: string): void;
27
+ /**
28
+ * Add key-value pair(s) to the test report
29
+ * @param {{[key: string]: string} | string} keyValue object { key: value } (multiple props allowed) or key (string)
30
+ * @param {string?} value
31
+ */
32
+ declare function setKeyValue(keyValue: {
33
+ [key: string]: string;
34
+ } | string, value?: string | null): void;
@@ -0,0 +1,232 @@
1
+ export type artifact = typeof import("./reporter-functions.js");
2
+ export const artifact: (data: string | {
3
+ path: string;
4
+ type: string;
5
+ name: string;
6
+ }, context?: any) => void;
7
+ export type log = typeof import("./reporter-functions.js");
8
+ export const log: (...args: any[]) => void;
9
+ export type logger = typeof import("./services/index.js");
10
+ export const logger: {
11
+ "__#12@#originalUserLogger": {
12
+ assert(condition?: boolean, ...data: any[]): void;
13
+ assert(value: any, message?: string, ...optionalParams: any[]): void;
14
+ clear(): void;
15
+ clear(): void;
16
+ count(label?: string): void;
17
+ count(label?: string): void;
18
+ countReset(label?: string): void;
19
+ countReset(label?: string): void;
20
+ debug(...data: any[]): void;
21
+ debug(message?: any, ...optionalParams: any[]): void;
22
+ dir(item?: any, options?: any): void;
23
+ dir(obj: any, options?: import("util").InspectOptions): void;
24
+ dirxml(...data: any[]): void;
25
+ dirxml(...data: any[]): void;
26
+ error(...data: any[]): void;
27
+ error(message?: any, ...optionalParams: any[]): void;
28
+ group(...data: any[]): void;
29
+ group(...label: any[]): void;
30
+ groupCollapsed(...data: any[]): void;
31
+ groupCollapsed(...label: any[]): void;
32
+ groupEnd(): void;
33
+ groupEnd(): void;
34
+ info(...data: any[]): void;
35
+ info(message?: any, ...optionalParams: any[]): void;
36
+ log(...data: any[]): void;
37
+ log(message?: any, ...optionalParams: any[]): void;
38
+ table(tabularData?: any, properties?: string[]): void;
39
+ table(tabularData: any, properties?: readonly string[]): void;
40
+ time(label?: string): void;
41
+ time(label?: string): void;
42
+ timeEnd(label?: string): void;
43
+ timeEnd(label?: string): void;
44
+ timeLog(label?: string, ...data: any[]): void;
45
+ timeLog(label?: string, ...data: any[]): void;
46
+ timeStamp(label?: string): void;
47
+ timeStamp(label?: string): void;
48
+ trace(...data: any[]): void;
49
+ trace(message?: any, ...optionalParams: any[]): void;
50
+ warn(...data: any[]): void;
51
+ warn(message?: any, ...optionalParams: any[]): void;
52
+ Console: console.ConsoleConstructor;
53
+ profile(label?: string): void;
54
+ profileEnd(label?: string): void;
55
+ };
56
+ "__#12@#userLoggerWithOverridenMethods": any;
57
+ logLevel: string;
58
+ step(strings: any, ...values: any[]): void;
59
+ getLogs(context: string): string[];
60
+ "__#12@#stringifyLogs"(...args: any[]): string;
61
+ _templateLiteralLog(strings: any, ...args: any[]): void;
62
+ "__#12@#logWrapper"(argsArray: any, level: any): void;
63
+ assert(...args: any[]): void;
64
+ debug(...args: any[]): void;
65
+ error(...args: any[]): void;
66
+ info(...args: any[]): void;
67
+ log(...args: any[]): void;
68
+ trace(...args: any[]): void;
69
+ warn(...args: any[]): void;
70
+ intercept(userLogger: any): void;
71
+ stopInterception(): void;
72
+ configure(config?: {
73
+ logLevel?: string;
74
+ prettyObjects?: boolean;
75
+ }): void;
76
+ prettyObjects: boolean;
77
+ };
78
+ export type meta = typeof import("./reporter-functions.js");
79
+ export const meta: (keyValue: {
80
+ [key: string]: string;
81
+ } | string, value?: string | null) => void;
82
+ export type step = typeof import("./reporter-functions.js");
83
+ export const step: (message: string) => void;
84
+ declare namespace _default {
85
+ let testomatioLogger: {
86
+ "__#12@#originalUserLogger": {
87
+ assert(condition?: boolean, ...data: any[]): void;
88
+ assert(value: any, message?: string, ...optionalParams: any[]): void;
89
+ clear(): void;
90
+ clear(): void;
91
+ count(label?: string): void;
92
+ count(label?: string): void;
93
+ countReset(label?: string): void;
94
+ countReset(label?: string): void;
95
+ debug(...data: any[]): void;
96
+ debug(message?: any, ...optionalParams: any[]): void;
97
+ dir(item?: any, options?: any): void;
98
+ dir(obj: any, options?: import("util").InspectOptions): void;
99
+ dirxml(...data: any[]): void;
100
+ dirxml(...data: any[]): void;
101
+ error(...data: any[]): void;
102
+ error(message?: any, ...optionalParams: any[]): void;
103
+ group(...data: any[]): void;
104
+ group(...label: any[]): void;
105
+ groupCollapsed(...data: any[]): void;
106
+ groupCollapsed(...label: any[]): void;
107
+ groupEnd(): void;
108
+ groupEnd(): void;
109
+ info(...data: any[]): void;
110
+ info(message?: any, ...optionalParams: any[]): void;
111
+ log(...data: any[]): void;
112
+ log(message?: any, ...optionalParams: any[]): void;
113
+ table(tabularData?: any, properties?: string[]): void;
114
+ table(tabularData: any, properties?: readonly string[]): void;
115
+ time(label?: string): void;
116
+ time(label?: string): void;
117
+ timeEnd(label?: string): void;
118
+ timeEnd(label?: string): void;
119
+ timeLog(label?: string, ...data: any[]): void;
120
+ timeLog(label?: string, ...data: any[]): void;
121
+ timeStamp(label?: string): void;
122
+ timeStamp(label?: string): void;
123
+ trace(...data: any[]): void;
124
+ trace(message?: any, ...optionalParams: any[]): void;
125
+ warn(...data: any[]): void;
126
+ warn(message?: any, ...optionalParams: any[]): void;
127
+ Console: console.ConsoleConstructor;
128
+ profile(label?: string): void;
129
+ profileEnd(label?: string): void;
130
+ };
131
+ "__#12@#userLoggerWithOverridenMethods": any;
132
+ logLevel: string;
133
+ step(strings: any, ...values: any[]): void;
134
+ getLogs(context: string): string[];
135
+ "__#12@#stringifyLogs"(...args: any[]): string;
136
+ _templateLiteralLog(strings: any, ...args: any[]): void;
137
+ "__#12@#logWrapper"(argsArray: any, level: any): void;
138
+ assert(...args: any[]): void;
139
+ debug(...args: any[]): void;
140
+ error(...args: any[]): void;
141
+ info(...args: any[]): void;
142
+ log(...args: any[]): void;
143
+ trace(...args: any[]): void;
144
+ warn(...args: any[]): void;
145
+ intercept(userLogger: any): void;
146
+ stopInterception(): void;
147
+ configure(config?: {
148
+ logLevel?: string;
149
+ prettyObjects?: boolean;
150
+ }): void;
151
+ prettyObjects: boolean;
152
+ };
153
+ let artifact: (data: string | {
154
+ path: string;
155
+ type: string;
156
+ name: string;
157
+ }, context?: any) => void;
158
+ let log: (...args: any[]) => void;
159
+ let logger: {
160
+ "__#12@#originalUserLogger": {
161
+ assert(condition?: boolean, ...data: any[]): void;
162
+ assert(value: any, message?: string, ...optionalParams: any[]): void;
163
+ clear(): void;
164
+ clear(): void;
165
+ count(label?: string): void;
166
+ count(label?: string): void;
167
+ countReset(label?: string): void;
168
+ countReset(label?: string): void;
169
+ debug(...data: any[]): void;
170
+ debug(message?: any, ...optionalParams: any[]): void;
171
+ dir(item?: any, options?: any): void;
172
+ dir(obj: any, options?: import("util").InspectOptions): void;
173
+ dirxml(...data: any[]): void;
174
+ dirxml(...data: any[]): void;
175
+ error(...data: any[]): void;
176
+ error(message?: any, ...optionalParams: any[]): void;
177
+ group(...data: any[]): void;
178
+ group(...label: any[]): void;
179
+ groupCollapsed(...data: any[]): void;
180
+ groupCollapsed(...label: any[]): void;
181
+ groupEnd(): void;
182
+ groupEnd(): void;
183
+ info(...data: any[]): void;
184
+ info(message?: any, ...optionalParams: any[]): void;
185
+ log(...data: any[]): void;
186
+ log(message?: any, ...optionalParams: any[]): void;
187
+ table(tabularData?: any, properties?: string[]): void;
188
+ table(tabularData: any, properties?: readonly string[]): void;
189
+ time(label?: string): void;
190
+ time(label?: string): void;
191
+ timeEnd(label?: string): void;
192
+ timeEnd(label?: string): void;
193
+ timeLog(label?: string, ...data: any[]): void;
194
+ timeLog(label?: string, ...data: any[]): void;
195
+ timeStamp(label?: string): void;
196
+ timeStamp(label?: string): void;
197
+ trace(...data: any[]): void;
198
+ trace(message?: any, ...optionalParams: any[]): void;
199
+ warn(...data: any[]): void;
200
+ warn(message?: any, ...optionalParams: any[]): void;
201
+ Console: console.ConsoleConstructor;
202
+ profile(label?: string): void;
203
+ profileEnd(label?: string): void;
204
+ };
205
+ "__#12@#userLoggerWithOverridenMethods": any;
206
+ logLevel: string;
207
+ step(strings: any, ...values: any[]): void;
208
+ getLogs(context: string): string[];
209
+ "__#12@#stringifyLogs"(...args: any[]): string;
210
+ _templateLiteralLog(strings: any, ...args: any[]): void;
211
+ "__#12@#logWrapper"(argsArray: any, level: any): void;
212
+ assert(...args: any[]): void;
213
+ debug(...args: any[]): void;
214
+ error(...args: any[]): void;
215
+ info(...args: any[]): void;
216
+ log(...args: any[]): void;
217
+ trace(...args: any[]): void;
218
+ warn(...args: any[]): void;
219
+ intercept(userLogger: any): void;
220
+ stopInterception(): void;
221
+ configure(config?: {
222
+ logLevel?: string;
223
+ prettyObjects?: boolean;
224
+ }): void;
225
+ prettyObjects: boolean;
226
+ };
227
+ let meta: (keyValue: {
228
+ [key: string]: string;
229
+ } | string, value?: string | null) => void;
230
+ let step: (message: string) => void;
231
+ }
232
+ export default _default;
@@ -0,0 +1,33 @@
1
+ export const artifactStorage: ArtifactStorage;
2
+ /**
3
+ * Artifact storage is supposed to store file paths
4
+ */
5
+ declare class ArtifactStorage {
6
+ static "__#13@#instance": any;
7
+ /**
8
+ * Singleton
9
+ * @returns {ArtifactStorage}
10
+ */
11
+ static getInstance(): ArtifactStorage;
12
+ /**
13
+ * Stores path to file as artifact and uploads it to the S3 storage
14
+ * @param {string | {path: string, type: string, name: string}} data - path to file or object with path, type and name
15
+ * @param {*} context testId or test title
16
+ */
17
+ put(data: string | {
18
+ path: string;
19
+ type: string;
20
+ name: string;
21
+ }, context?: any): void;
22
+ /**
23
+ * Returns list of artifacts to upload
24
+ * @param {*} context testId or test context from test runner
25
+ * @returns {(string | {path: string, type: string, name: string})[]}
26
+ */
27
+ get(context: any): (string | {
28
+ path: string;
29
+ type: string;
30
+ name: string;
31
+ })[];
32
+ }
33
+ export {};
@@ -0,0 +1,9 @@
1
+ export namespace services {
2
+ export { logger };
3
+ export { artifactStorage as artifacts };
4
+ export { keyValueStorage as keyValues };
5
+ export function setContext(context: any): void;
6
+ }
7
+ import { logger } from './logger.js';
8
+ import { artifactStorage } from './artifacts.js';
9
+ import { keyValueStorage } from './key-values.js';
@@ -0,0 +1,27 @@
1
+ export const keyValueStorage: KeyValueStorage;
2
+ declare class KeyValueStorage {
3
+ static "__#14@#instance": any;
4
+ /**
5
+ *
6
+ * @returns {KeyValueStorage}
7
+ */
8
+ static getInstance(): KeyValueStorage;
9
+ /**
10
+ * Stores key-value pair and passes it to reporter
11
+ * @param {{[key: string]: string}} keyValue - key-value pair(s) as object
12
+ * @param {*} context - full test title
13
+ */
14
+ put(keyValue: {
15
+ [key: string]: string;
16
+ }, context?: any): void;
17
+ /**
18
+ * Returns key-values pairs for the test as object
19
+ * @param {*} context testId or test context from test runner
20
+ * @returns {{[key: string]: string} | {}} key-values pairs as object, e.g. {priority: 'high', browser: 'chrome'}
21
+ */
22
+ get(context?: any): {
23
+ [key: string]: string;
24
+ } | {};
25
+ #private;
26
+ }
27
+ export {};
@@ -0,0 +1,64 @@
1
+ export const logger: Logger;
2
+ /**
3
+ * Logger allows to intercept logs from any logger (console.log, tracer, pino, etc)
4
+ * and save in the testomatio reporter.
5
+ * Supports different syntaxes to satisfy any user preferences.
6
+ */
7
+ declare class Logger {
8
+ static "__#12@#instance": any;
9
+ /**
10
+ *
11
+ * @returns {Logger}
12
+ */
13
+ static getInstance(): Logger;
14
+ logLevel: string;
15
+ /**
16
+ * Allows you to define a step inside a test. Step name is attached to the report and
17
+ * helps to understand the test flow.
18
+ * @param {*} strings
19
+ * @param {...any} values
20
+ */
21
+ step(strings: any, ...values: any[]): void;
22
+ /**
23
+ *
24
+ * @param {string} context testId or test context from test runner
25
+ * @returns {string[]}
26
+ */
27
+ getLogs(context: string): string[];
28
+ /**
29
+ * Tagget template literal. Allows to use different syntaxes:
30
+ * 1. Tagget template: log`text ${someVar}`
31
+ * 2. Standard: log(`text ${someVar}`)
32
+ * 3. Standard with multiple arguments: log('text', someVar)
33
+ */
34
+ _templateLiteralLog(strings: any, ...args: any[]): void;
35
+ assert(...args: any[]): void;
36
+ debug(...args: any[]): void;
37
+ error(...args: any[]): void;
38
+ info(...args: any[]): void;
39
+ log(...args: any[]): void;
40
+ trace(...args: any[]): void;
41
+ warn(...args: any[]): void;
42
+ /**
43
+ * Intercepts user logger messages.
44
+ * When call this method, Logger start to control the user logger
45
+ * @param {*} userLogger
46
+ */
47
+ intercept(userLogger: any): void;
48
+ stopInterception(): void;
49
+ /**
50
+ * Allows to configure logger. Make sure you do it before the logger usage in your code.
51
+ *
52
+ * @param {Object} [config={}] - The configuration object.
53
+ * @param {string} [config.logLevel] - The desired log level. Valid values are 'DEBUG', 'INFO', 'WARN', and 'ERROR'.
54
+ * @param {boolean} [config.prettyObjects] - Specifies whether to enable pretty printing of objects.
55
+ * @returns {void}
56
+ */
57
+ configure(config?: {
58
+ logLevel?: string;
59
+ prettyObjects?: boolean;
60
+ }): void;
61
+ prettyObjects: boolean;
62
+ #private;
63
+ }
64
+ export {};
@@ -0,0 +1,60 @@
1
+ export class S3Uploader {
2
+ isEnabled: any;
3
+ storeEnabled: boolean;
4
+ config: {};
5
+ /**
6
+ * @type {{path: string, size: number}[]}
7
+ */
8
+ skippedUploads: {
9
+ path: string;
10
+ size: number;
11
+ }[];
12
+ failedUploads: any[];
13
+ /**
14
+ * @type {{path: string, size: number, link: string}[]}
15
+ */
16
+ successfulUploads: {
17
+ path: string;
18
+ size: number;
19
+ link: string;
20
+ }[];
21
+ configKeys: string[];
22
+ resetConfig(): void;
23
+ /**
24
+ *
25
+ * @returns {Record<string, string>}
26
+ */
27
+ getConfig(): Record<string, string>;
28
+ getMaskedConfig(): {
29
+ [k: string]: string;
30
+ };
31
+ checkEnabled(): any;
32
+ enableLogStorage(): void;
33
+ disableLogStorage(): void;
34
+ /**
35
+ * Returns an array of uploaded files
36
+ *
37
+ * @returns {{rid: string, file: string, uploaded: boolean}[]}
38
+ */
39
+ readUploadedFiles(runId: any): {
40
+ rid: string;
41
+ file: string;
42
+ uploaded: boolean;
43
+ }[];
44
+ storeUploadedFile(filePath: any, runId: any, rid: any, uploaded?: boolean): void;
45
+ /**
46
+ * @param {*} filePath
47
+ * @param {*} pathInS3 contains runId, rid and filename
48
+ * @returns
49
+ */
50
+ uploadFileByPath(filePath: any, pathInS3: any): Promise<any>;
51
+ /**
52
+ * @param {Buffer} buffer
53
+ * @param {string[]} pathInS3
54
+ * @returns
55
+ */
56
+ uploadFileAsBuffer(buffer: Buffer, pathInS3: string[]): Promise<any>;
57
+ checkArtifactExistsInFileSystem(filePath: any, attempts?: number, intervalMs?: number): Promise<any>;
58
+ getS3LocationLink(out: any): Promise<any>;
59
+ #private;
60
+ }
@@ -0,0 +1,41 @@
1
+ /**
2
+ * Update and validate the filter type.
3
+ * @param {string} type - The original filter type.
4
+ * @returns {string|undefined} The updated and validated filter type.
5
+ * Returns undefined if the type is not valid.
6
+ */
7
+ export function updateFilterType(type: string): string | undefined;
8
+ /**
9
+ * Parse filter parameters from a string in the format "type=id".
10
+ * @param {string} opts - The input string containing the filter parameters.
11
+ * @returns {Object} An object containing the parsed filter parameters.
12
+ * The object has properties "type" and "id".
13
+ */
14
+ export function parseFilterParams(opts: string): any;
15
+ /**
16
+ * Generates mode request parameters based on the input params.
17
+ * @param {{type: string, id?: string, apiKey: string}} params - The input parameters for the request.
18
+ * @returns {Object|null} - An object containing the generated request parameters, or null if the type is invalid.
19
+ */
20
+ export function generateFilterRequestParams(params: {
21
+ type: string;
22
+ id?: string;
23
+ apiKey: string;
24
+ }): any | null;
25
+ /**
26
+ * Set S3 credentials from the provided artifacts object.
27
+ * @param {Object} artifacts - The artifacts object containing S3 credentials.
28
+ */
29
+ export function setS3Credentials(artifacts: any): void;
30
+ /**
31
+ * Return an emoji based on the provided status.
32
+ * @param {string} status - The status value ('passed', 'failed', or 'skipped').
33
+ * @returns {string} - An emoji corresponding to the provided status.
34
+ */
35
+ export function statusEmoji(status: string): string;
36
+ /**
37
+ * Generate a full name string based on the provided test object.
38
+ * @param {object} t - The test object.
39
+ * @returns {string} - A formatted full name string for the test object.
40
+ */
41
+ export function fullName(t: object): string;
@@ -0,0 +1,45 @@
1
+ export function ansiRegExp(): RegExp;
2
+ export function isSameTest(test: any, t: any): boolean;
3
+ export function fetchSourceCode(contents: any, opts?: {}): string;
4
+ export function fetchSourceCodeFromStackTrace(stack?: string): string;
5
+ export function fetchIdFromCode(code: any, opts?: {}): any;
6
+ export function fetchIdFromOutput(output: any): any;
7
+ export function fetchFilesFromStackTrace(stack?: string): string[];
8
+ export namespace fileSystem {
9
+ function createDir(dirPath: any): void;
10
+ function clearDir(dirPath: any): void;
11
+ }
12
+ export function foundedTestLog(app: any, tests: any): void;
13
+ export function formatStep(step: any, shift?: number): any;
14
+ export function getCurrentDateTime(): string;
15
+ /**
16
+ * @param {String} testTitle - Test title
17
+ *
18
+ * @returns {String|null} testId
19
+ */
20
+ export function getTestomatIdFromTestTitle(testTitle: string): string | null;
21
+ export function humanize(text: any): any;
22
+ export function isValidUrl(s: any): boolean;
23
+ /**
24
+ * @param {String} suiteTitle - suite title
25
+ *
26
+ * @returns {String|null} suiteId
27
+ */
28
+ export function parseSuite(suiteTitle: string): string | null;
29
+ export function readLatestRunId(): string;
30
+ /**
31
+ * Used to remove color codes
32
+ * @param {*} input
33
+ * @returns
34
+ */
35
+ export function removeColorCodes(input: any): any;
36
+ /**
37
+ * @param {Object} test - Test adapter object
38
+ *
39
+ * @returns {String|null} testInfo as one string
40
+ */
41
+ export function specificTestInfo(test: any): string | null;
42
+ export function storeRunId(runId: any): void;
43
+ export namespace testRunnerHelper {
44
+ function getNameOfCurrentlyRunningTest(): any;
45
+ }