@wdio/sumologic-reporter 7.20.8-alpha.219 → 7.24.0

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/build/index.d.ts CHANGED
@@ -22,7 +22,7 @@ export default class SumoLogicReporter extends WDIOReporter {
22
22
  onRunnerEnd(runner: RunnerStats): void;
23
23
  sync(): Promise<void>;
24
24
  }
25
- export * from './types.js';
25
+ export * from './types';
26
26
  declare global {
27
27
  namespace WebdriverIO {
28
28
  interface ReporterOption extends Options {
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAIA,OAAO,YAAY,EAAE,EAAE,WAAW,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAA;AAGjF,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,SAAS,CAAA;AAOtC;;GAEG;AACH,MAAM,CAAC,OAAO,OAAO,iBAAkB,SAAQ,YAAY;IACvD,OAAO,CAAC,QAAQ,CAAS;IACzB,OAAO,CAAC,SAAS,CAAgB;IAEjC,OAAO,CAAC,SAAS,CAAe;IAChC,OAAO,CAAC,gBAAgB,CAAQ;IAChC,OAAO,CAAC,aAAa,CAAQ;gBAEjB,OAAO,EAAE,OAAO;IAmB5B,IAAI,cAAc,YAEjB;IAED,aAAa,CAAC,MAAM,EAAE,WAAW;IAQjC,YAAY,CAAC,KAAK,EAAE,UAAU;IAQ9B,WAAW,CAAC,IAAI,EAAE,SAAS;IAQ3B,UAAU,CAAC,IAAI,EAAE,SAAS;IAQ1B,UAAU,CAAC,IAAI,EAAE,SAAS;IAQ1B,UAAU,CAAC,IAAI,EAAE,SAAS;IAQ1B,SAAS,CAAC,IAAI,EAAE,SAAS;IAQzB,UAAU,CAAC,KAAK,EAAE,UAAU;IAQ5B,WAAW,CAAC,MAAM,EAAE,WAAW;IASzB,IAAI;CA8Cb;AAED,cAAc,YAAY,CAAA;AAE1B,OAAO,CAAC,MAAM,CAAC;IACX,UAAU,WAAW,CAAC;QAClB,UAAU,cAAe,SAAQ,OAAO;SAAG;KAC9C;CACJ"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAIA,OAAO,YAAY,EAAE,EAAE,WAAW,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAA;AAGjF,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,SAAS,CAAA;AAOtC;;GAEG;AACH,MAAM,CAAC,OAAO,OAAO,iBAAkB,SAAQ,YAAY;IACvD,OAAO,CAAC,QAAQ,CAAS;IACzB,OAAO,CAAC,SAAS,CAAgB;IAEjC,OAAO,CAAC,SAAS,CAAe;IAChC,OAAO,CAAC,gBAAgB,CAAQ;IAChC,OAAO,CAAC,aAAa,CAAQ;gBAEjB,OAAO,EAAE,OAAO;IAmB5B,IAAI,cAAc,YAEjB;IAED,aAAa,CAAC,MAAM,EAAE,WAAW;IAQjC,YAAY,CAAC,KAAK,EAAE,UAAU;IAQ9B,WAAW,CAAC,IAAI,EAAE,SAAS;IAQ3B,UAAU,CAAC,IAAI,EAAE,SAAS;IAQ1B,UAAU,CAAC,IAAI,EAAE,SAAS;IAQ1B,UAAU,CAAC,IAAI,EAAE,SAAS;IAQ1B,SAAS,CAAC,IAAI,EAAE,SAAS;IAQzB,UAAU,CAAC,KAAK,EAAE,UAAU;IAQ5B,WAAW,CAAC,MAAM,EAAE,WAAW;IASzB,IAAI;CA8Cb;AAED,cAAc,SAAS,CAAA;AAEvB,OAAO,CAAC,MAAM,CAAC;IACX,UAAU,WAAW,CAAC;QAClB,UAAU,cAAe,SAAQ,OAAO;SAAG;KAC9C;CACJ"}
package/build/index.js CHANGED
@@ -1,15 +1,34 @@
1
- import got from 'got';
2
- import dateFormat from 'dateformat';
3
- import stringify from 'json-stringify-safe';
4
- import WDIOReporter from '@wdio/reporter';
5
- import logger from '@wdio/logger';
6
- const log = logger('@wdio/sumologic-reporter');
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ var __importDefault = (this && this.__importDefault) || function (mod) {
17
+ return (mod && mod.__esModule) ? mod : { "default": mod };
18
+ };
19
+ Object.defineProperty(exports, "__esModule", { value: true });
20
+ const got_1 = __importDefault(require("got"));
21
+ const dateformat_1 = __importDefault(require("dateformat"));
22
+ const json_stringify_safe_1 = __importDefault(require("json-stringify-safe"));
23
+ const reporter_1 = __importDefault(require("@wdio/reporter"));
24
+ const logger_1 = __importDefault(require("@wdio/logger"));
25
+ const log = (0, logger_1.default)('@wdio/sumologic-reporter');
7
26
  const MAX_LINES = 100;
8
27
  const DATE_FORMAT = 'yyyy-mm-dd HH:mm:ss,l o';
9
28
  /**
10
29
  * Initialize a new sumologic test reporter.
11
30
  */
12
- export default class SumoLogicReporter extends WDIOReporter {
31
+ class SumoLogicReporter extends reporter_1.default {
13
32
  constructor(options) {
14
33
  super(options);
15
34
  this._unsynced = [];
@@ -33,65 +52,65 @@ export default class SumoLogicReporter extends WDIOReporter {
33
52
  return this._unsynced.length === 0;
34
53
  }
35
54
  onRunnerStart(runner) {
36
- this._unsynced.push(stringify({
37
- time: dateFormat(new Date(), DATE_FORMAT),
55
+ this._unsynced.push((0, json_stringify_safe_1.default)({
56
+ time: (0, dateformat_1.default)(new Date(), DATE_FORMAT),
38
57
  event: 'runner:start',
39
58
  data: runner
40
59
  }));
41
60
  }
42
61
  onSuiteStart(suite) {
43
- this._unsynced.push(stringify({
44
- time: dateFormat(new Date(), DATE_FORMAT),
62
+ this._unsynced.push((0, json_stringify_safe_1.default)({
63
+ time: (0, dateformat_1.default)(new Date(), DATE_FORMAT),
45
64
  event: 'suite:start',
46
65
  data: suite
47
66
  }));
48
67
  }
49
68
  onTestStart(test) {
50
- this._unsynced.push(stringify({
51
- time: dateFormat(new Date(), DATE_FORMAT),
69
+ this._unsynced.push((0, json_stringify_safe_1.default)({
70
+ time: (0, dateformat_1.default)(new Date(), DATE_FORMAT),
52
71
  event: 'test:start',
53
72
  data: test
54
73
  }));
55
74
  }
56
75
  onTestSkip(test) {
57
- this._unsynced.push(stringify({
58
- time: dateFormat(new Date(), DATE_FORMAT),
76
+ this._unsynced.push((0, json_stringify_safe_1.default)({
77
+ time: (0, dateformat_1.default)(new Date(), DATE_FORMAT),
59
78
  event: 'test:skip',
60
79
  data: test
61
80
  }));
62
81
  }
63
82
  onTestPass(test) {
64
- this._unsynced.push(stringify({
65
- time: dateFormat(new Date(), DATE_FORMAT),
83
+ this._unsynced.push((0, json_stringify_safe_1.default)({
84
+ time: (0, dateformat_1.default)(new Date(), DATE_FORMAT),
66
85
  event: 'test:pass',
67
86
  data: test
68
87
  }));
69
88
  }
70
89
  onTestFail(test) {
71
- this._unsynced.push(stringify({
72
- time: dateFormat(new Date(), DATE_FORMAT),
90
+ this._unsynced.push((0, json_stringify_safe_1.default)({
91
+ time: (0, dateformat_1.default)(new Date(), DATE_FORMAT),
73
92
  event: 'test:fail',
74
93
  data: test
75
94
  }));
76
95
  }
77
96
  onTestEnd(test) {
78
- this._unsynced.push(stringify({
79
- time: dateFormat(new Date(), DATE_FORMAT),
97
+ this._unsynced.push((0, json_stringify_safe_1.default)({
98
+ time: (0, dateformat_1.default)(new Date(), DATE_FORMAT),
80
99
  event: 'test:end',
81
100
  data: test
82
101
  }));
83
102
  }
84
103
  onSuiteEnd(suite) {
85
- this._unsynced.push(stringify({
86
- time: dateFormat(new Date(), DATE_FORMAT),
104
+ this._unsynced.push((0, json_stringify_safe_1.default)({
105
+ time: (0, dateformat_1.default)(new Date(), DATE_FORMAT),
87
106
  event: 'suite:end',
88
107
  data: suite
89
108
  }));
90
109
  }
91
110
  onRunnerEnd(runner) {
92
111
  this._hasRunnerEnd = true;
93
- this._unsynced.push(stringify({
94
- time: dateFormat(new Date(), DATE_FORMAT),
112
+ this._unsynced.push((0, json_stringify_safe_1.default)({
113
+ time: (0, dateformat_1.default)(new Date(), DATE_FORMAT),
95
114
  event: 'runner:end',
96
115
  data: runner
97
116
  }));
@@ -119,7 +138,7 @@ export default class SumoLogicReporter extends WDIOReporter {
119
138
  this._isSynchronising = true;
120
139
  log.debug('start synchronization');
121
140
  try {
122
- const resp = await got(this._options.sourceAddress, {
141
+ const resp = await (0, got_1.default)(this._options.sourceAddress, {
123
142
  method: 'POST',
124
143
  json: logLines
125
144
  });
@@ -138,4 +157,5 @@ export default class SumoLogicReporter extends WDIOReporter {
138
157
  }
139
158
  }
140
159
  }
141
- export * from './types.js';
160
+ exports.default = SumoLogicReporter;
161
+ __exportStar(require("./types"), exports);
package/build/types.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import type { Reporters } from '@wdio/types';
1
+ import { Reporters } from '@wdio/types';
2
2
  export interface Options extends Partial<Reporters.Options> {
3
3
  /**
4
4
  * define sync interval how often logs get pushed to Sumologic
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,aAAa,CAAA;AAE5C,MAAM,WAAW,OAAQ,SAAQ,OAAO,CAAC,SAAS,CAAC,OAAO,CAAC;IACvD;;;OAGG;IACH,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB;;;;;;OAMG;IACH,aAAa,CAAC,EAAE,MAAM,CAAA;CACzB"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAA;AAEvC,MAAM,WAAW,OAAQ,SAAQ,OAAO,CAAC,SAAS,CAAC,OAAO,CAAC;IACvD;;;OAGG;IACH,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB;;;;;;OAMG;IACH,aAAa,CAAC,EAAE,MAAM,CAAA;CACzB"}
package/build/types.js CHANGED
@@ -1 +1,2 @@
1
- export {};
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
package/package.json CHANGED
@@ -1,12 +1,13 @@
1
1
  {
2
2
  "name": "@wdio/sumologic-reporter",
3
- "version": "7.20.8-alpha.219+4aab2cef1",
3
+ "version": "7.24.0",
4
4
  "description": "A WebdriverIO reporter that sends test results to Sumologic for data analyses",
5
5
  "author": "Christian Bromann <mail@bromann.dev>",
6
6
  "homepage": "https://github.com/webdriverio/webdriverio/tree/main/packages/wdio-sumologic-reporter",
7
7
  "license": "MIT",
8
+ "main": "./build/index",
8
9
  "engines": {
9
- "node": "^16.13 || >=18"
10
+ "node": ">=12.0.0"
10
11
  },
11
12
  "repository": {
12
13
  "type": "git",
@@ -20,25 +21,22 @@
20
21
  "bugs": {
21
22
  "url": "https://github.com/webdriverio/webdriverio/issues"
22
23
  },
23
- "type": "module",
24
- "exports": "./build/index.js",
25
- "types": "./build/index.d.ts",
26
- "typeScriptVersion": "3.8.3",
27
24
  "dependencies": {
28
25
  "@types/dateformat": "^5.0.0",
29
26
  "@types/json-stringify-safe": "^5.0.0",
30
27
  "@wdio/logger": "7.19.0",
31
- "@wdio/reporter": "7.20.7",
32
- "@wdio/types": "7.20.7",
28
+ "@wdio/reporter": "7.24.0",
29
+ "@wdio/types": "7.24.0",
33
30
  "dateformat": "4.5.1",
34
- "got": "^12.1.0",
31
+ "got": "^11.0.2",
35
32
  "json-stringify-safe": "^5.0.1"
36
33
  },
37
34
  "peerDependencies": {
38
- "@wdio/cli": "next"
35
+ "@wdio/cli": "^7.0.0"
39
36
  },
40
37
  "publishConfig": {
41
38
  "access": "public"
42
39
  },
43
- "gitHead": "4aab2cef1b8b195ac8cc611f28b1fd54e4ba3443"
40
+ "types": "./build/index.d.ts",
41
+ "gitHead": "cf88ab19bcd0d097ebf00fb812fcbfd1caef9705"
44
42
  }