@serenity-js/cucumber 3.25.0 → 3.25.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/CHANGELOG.md +19 -0
- package/README.md +1 -1
- package/lib/adapter/CucumberCLIAdapter.d.ts +3 -3
- package/lib/adapter/CucumberCLIAdapter.js +3 -3
- package/lib/adapter/CucumberConfig.d.ts +2 -2
- package/lib/adapter/CucumberOptions.d.ts +1 -7
- package/lib/adapter/CucumberOptions.d.ts.map +1 -1
- package/lib/adapter/CucumberOptions.js +1 -7
- package/lib/adapter/CucumberOptions.js.map +1 -1
- package/lib/index.d.ts +1 -1
- package/lib/index.js +1 -1
- package/lib/listeners/messages/index.d.ts +1 -5
- package/lib/listeners/messages/index.d.ts.map +1 -1
- package/lib/listeners/messages/index.js +1 -5
- package/lib/listeners/messages/index.js.map +1 -1
- package/package.json +4 -4
- package/src/adapter/CucumberCLIAdapter.ts +3 -3
- package/src/adapter/CucumberConfig.ts +2 -2
- package/src/adapter/CucumberOptions.ts +1 -7
- package/src/index.ts +1 -1
- package/src/listeners/messages/index.ts +1 -5
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,25 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [3.25.2](https://github.com/serenity-js/serenity-js/compare/v3.25.1...v3.25.2) (2024-07-17)
|
|
7
|
+
|
|
8
|
+
**Note:** Version bump only for package @serenity-js/cucumber
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
## [3.25.1](https://github.com/serenity-js/serenity-js/compare/v3.25.0...v3.25.1) (2024-07-10)
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
### Bug Fixes
|
|
18
|
+
|
|
19
|
+
* **core:** all the API docs now link to the online Serenity/JS API documentation ([f8f451d](https://github.com/serenity-js/serenity-js/commit/f8f451dffdb4caaa2e31a860f59d59470f4856ad))
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
|
|
6
25
|
# [3.25.0](https://github.com/serenity-js/serenity-js/compare/v3.24.1...v3.25.0) (2024-07-03)
|
|
7
26
|
|
|
8
27
|
**Note:** Version bump only for package @serenity-js/cucumber
|
package/README.md
CHANGED
|
@@ -17,7 +17,7 @@ of complex software systems faster, more collaborative and easier to scale.
|
|
|
17
17
|
👋 Join the Serenity/JS Community!
|
|
18
18
|
- Meet other Serenity/JS developers and maintainers on the [Serenity/JS Community chat channel](https://matrix.to/#/#serenity-js:gitter.im),
|
|
19
19
|
- Find answers to your Serenity/JS questions on the [Serenity/JS Forum](https://github.com/orgs/serenity-js/discussions/categories/how-do-i),
|
|
20
|
-
- Learn how to [contribute to Serenity/JS](https://serenity-js.org/contributing),
|
|
20
|
+
- Learn how to [contribute to Serenity/JS](https://serenity-js.org/community/contributing/),
|
|
21
21
|
- Support the project and gain access to [Serenity/JS Playbooks](https://github.com/serenity-js/playbooks) by becoming a [Serenity/JS GitHub Sponsor](https://github.com/sponsors/serenity-js)!
|
|
22
22
|
|
|
23
23
|
## Serenity/JS Cucumber
|
|
@@ -7,7 +7,7 @@ import type { SerenityFormatterOutput } from './output';
|
|
|
7
7
|
* Allows for programmatic execution of Cucumber test scenarios.
|
|
8
8
|
*
|
|
9
9
|
* ## Learn more
|
|
10
|
-
* -
|
|
10
|
+
* - [`TestRunnerAdapter`](https://serenity-js.org/api/core-adapter/interface/TestRunnerAdapter/)
|
|
11
11
|
*
|
|
12
12
|
* @group Integration
|
|
13
13
|
*/
|
|
@@ -18,7 +18,7 @@ export declare class CucumberCLIAdapter implements TestRunnerAdapter {
|
|
|
18
18
|
private readonly options;
|
|
19
19
|
constructor(config: CucumberConfig, loader: ModuleLoader, fileSystem: FileSystem, output: SerenityFormatterOutput);
|
|
20
20
|
/**
|
|
21
|
-
* Scenario success threshold for this test runner, calculated based on
|
|
21
|
+
* Scenario success threshold for this test runner, calculated based on [`CucumberConfig`](https://serenity-js.org/api/cucumber-adapter/interface/CucumberConfig/)
|
|
22
22
|
*/
|
|
23
23
|
successThreshold(): Outcome | {
|
|
24
24
|
Code: number;
|
|
@@ -33,7 +33,7 @@ export declare class CucumberCLIAdapter implements TestRunnerAdapter {
|
|
|
33
33
|
/**
|
|
34
34
|
* Returns the number of loaded scenarios
|
|
35
35
|
*
|
|
36
|
-
* @throws
|
|
36
|
+
* @throws [`LogicError`](https://serenity-js.org/api/core/class/LogicError/)
|
|
37
37
|
* If called before `load`
|
|
38
38
|
*/
|
|
39
39
|
scenarioCount(): number;
|
|
@@ -32,7 +32,7 @@ const CucumberOptions_1 = require("./CucumberOptions");
|
|
|
32
32
|
* Allows for programmatic execution of Cucumber test scenarios.
|
|
33
33
|
*
|
|
34
34
|
* ## Learn more
|
|
35
|
-
* -
|
|
35
|
+
* - [`TestRunnerAdapter`](https://serenity-js.org/api/core-adapter/interface/TestRunnerAdapter/)
|
|
36
36
|
*
|
|
37
37
|
* @group Integration
|
|
38
38
|
*/
|
|
@@ -47,7 +47,7 @@ class CucumberCLIAdapter {
|
|
|
47
47
|
this.options = new CucumberOptions_1.CucumberOptions(new io_1.FileFinder(io_1.Path.from(this.loader.cwd)), fileSystem, config);
|
|
48
48
|
}
|
|
49
49
|
/**
|
|
50
|
-
* Scenario success threshold for this test runner, calculated based on
|
|
50
|
+
* Scenario success threshold for this test runner, calculated based on [`CucumberConfig`](https://serenity-js.org/api/cucumber-adapter/interface/CucumberConfig/)
|
|
51
51
|
*/
|
|
52
52
|
successThreshold() {
|
|
53
53
|
return this.options.isStrict()
|
|
@@ -73,7 +73,7 @@ class CucumberCLIAdapter {
|
|
|
73
73
|
/**
|
|
74
74
|
* Returns the number of loaded scenarios
|
|
75
75
|
*
|
|
76
|
-
* @throws
|
|
76
|
+
* @throws [`LogicError`](https://serenity-js.org/api/core/class/LogicError/)
|
|
77
77
|
* If called before `load`
|
|
78
78
|
*/
|
|
79
79
|
scenarioCount() {
|
|
@@ -38,7 +38,7 @@ export interface CucumberConfig {
|
|
|
38
38
|
* Enable/disable colors in output. Cucumber 1.x only!
|
|
39
39
|
* For Cucumber 2.x and above use `formatOptions: { colorsEnabled: false }`
|
|
40
40
|
*
|
|
41
|
-
* **Note** For Cucumber 2.x and above use the
|
|
41
|
+
* **Note** For Cucumber 2.x and above use the [`CucumberConfig.formatOptions`](https://serenity-js.org/api/cucumber-adapter/interface/CucumberConfig/#formatOptions) instead.
|
|
42
42
|
*
|
|
43
43
|
* #### Disable colors in output in Cucumber 1.x
|
|
44
44
|
*
|
|
@@ -62,7 +62,7 @@ export interface CucumberConfig {
|
|
|
62
62
|
* Step definitions and support files can be written in languages that transpile to JavaScript.
|
|
63
63
|
* To do set the `compiler` option to `<file_extension>:<module_name>`
|
|
64
64
|
*
|
|
65
|
-
* **NoteL** For Cucumber 4.x and above use the
|
|
65
|
+
* **NoteL** For Cucumber 4.x and above use the [`CucumberConfig.require`](https://serenity-js.org/api/cucumber-adapter/interface/CucumberConfig/#require) option instead.
|
|
66
66
|
*
|
|
67
67
|
* #### Enable TypeScript support in Cucumber 1.x - 3.x
|
|
68
68
|
* ```ts
|
|
@@ -19,13 +19,7 @@ export declare class CucumberOptions {
|
|
|
19
19
|
private asBoolean;
|
|
20
20
|
private isObject;
|
|
21
21
|
/**
|
|
22
|
-
*
|
|
23
|
-
* Converts camelCase option names to kebab-case.
|
|
24
|
-
*
|
|
25
|
-
* @param {string} option
|
|
26
|
-
* @returns {string}
|
|
27
|
-
*
|
|
28
|
-
* @private
|
|
22
|
+
* Converts camelCase option names to kebab-case.
|
|
29
23
|
*/
|
|
30
24
|
private asCliOptionName;
|
|
31
25
|
private tagsToCucumberExpressions;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CucumberOptions.d.ts","sourceRoot":"","sources":["../../src/adapter/CucumberOptions.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK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EACtB,MAAM,EAAE,cAAc;IAI3C,QAAQ,IAAI,OAAO;IAInB,sBAAsB,CAAC,OAAO,EAAE,OAAO,GAAG,MAAM,EAAE;IAgBlD,OAAO,CAAC,OAAO;IAYf,0BAA0B,IAAI,OAAO,CAAC,cAAc,CAAC;IAgCrD,OAAO,CAAC,4BAA4B;IAUpC,OAAO,CAAC,cAAc;IAiBtB,OAAO,CAAC,SAAS;IAYjB,OAAO,CAAC,QAAQ;IAMhB;;OAEG;IACH,OAAO,CAAC,eAAe;IAMvB,OAAO,CAAC,yBAAyB;IAMjC,OAAO,CAAC,SAAS;IAWjB,OAAO,CAAC,YAAY;CAKvB"}
|
|
@@ -101,13 +101,7 @@ class CucumberOptions {
|
|
|
101
101
|
&& Object.prototype.toString.call(value) === '[object Object]';
|
|
102
102
|
}
|
|
103
103
|
/**
|
|
104
|
-
*
|
|
105
|
-
* Converts camelCase option names to kebab-case.
|
|
106
|
-
*
|
|
107
|
-
* @param {string} option
|
|
108
|
-
* @returns {string}
|
|
109
|
-
*
|
|
110
|
-
* @private
|
|
104
|
+
* Converts camelCase option names to kebab-case.
|
|
111
105
|
*/
|
|
112
106
|
asCliOptionName(option) {
|
|
113
107
|
return option
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CucumberOptions.js","sourceRoot":"","sources":["../../src/adapter/CucumberOptions.ts"],"names":[],"mappings":";;;AACA,4CAAuD;AAEvD,iDAAyD;AAIzD;;GAEG;AACH,MAAa,eAAe;IAEH;IACA;IACA;IAHrB,YACqB,MAAkB,EAClB,UAAsB,EACtB,MAAsB;QAFtB,WAAM,GAAN,MAAM,CAAY;QAClB,eAAU,GAAV,UAAU,CAAY;QACtB,WAAM,GAAN,MAAM,CAAgB;IAE3C,CAAC;IAED,QAAQ;QACJ,OAAO,IAAI,CAAC,SAAS,CAAC,QAAQ,EAAE,IAAI,CAAC,CAAC;IAC1C,CAAC;IAED,sBAAsB,CAAC,OAAgB;QAEnC,OAAO,MAAM,CA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CAAC,CAAC,CAAC,CAAC,WAAW,EAAE,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;AAC/D,CAAC;AAED,SAAS,UAAU,CAAC,KAAU;IAC1B,OAAO,KAAK,KAAK,SAAS;WACnB,KAAK,KAAK,IAAI;WACd,KAAK,KAAK,EAAE;WACZ,CAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,KAAK,CAAC,MAAM,KAAK,CAAC,CAAC,CAAC;AAC1D,CAAC;AAED,SAAS,MAAM,CAAI,aAAsB;IACrC,OAAO,EAAE,CAAC,MAAM,CAAC,aAAa,CAAC,CAAC,MAAM,CAAC,UAAU,CAAC,CAAC;AACvD,CAAC"}
|
package/lib/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Registers a Cucumber reporter that emits
|
|
2
|
+
* Registers a Cucumber reporter that emits [Serenity/JS domain events](https://serenity-js.org/api/core-events/class/DomainEvent/)
|
|
3
3
|
* and informs Serenity/JS when test scenarios and Cucumber steps start, finish, and with what result.
|
|
4
4
|
*/
|
|
5
5
|
declare const listener: unknown;
|
package/lib/index.js
CHANGED
|
@@ -31,7 +31,7 @@ const version = loader.hasAvailable('@cucumber/cucumber')
|
|
|
31
31
|
? loader.versionOf('@cucumber/cucumber')
|
|
32
32
|
: loader.versionOf('cucumber');
|
|
33
33
|
/**
|
|
34
|
-
* Registers a Cucumber reporter that emits
|
|
34
|
+
* Registers a Cucumber reporter that emits [Serenity/JS domain events](https://serenity-js.org/api/core-events/class/DomainEvent/)
|
|
35
35
|
* and informs Serenity/JS when test scenarios and Cucumber steps start, finish, and with what result.
|
|
36
36
|
*/
|
|
37
37
|
const listener = version.isAtLeast(new io_1.Version('7.0.0'))
|
|
@@ -1,11 +1,7 @@
|
|
|
1
1
|
import type { Serenity } from '@serenity-js/core';
|
|
2
2
|
import type { ModuleLoader } from '@serenity-js/core/lib/io';
|
|
3
3
|
/**
|
|
4
|
-
*
|
|
5
|
-
* Creates a listener for Cucumber.js v7.x and above
|
|
6
|
-
*
|
|
7
|
-
* @param serenity
|
|
8
|
-
* @param moduleLoader
|
|
4
|
+
* Creates a listener for Cucumber.js v7.x and above
|
|
9
5
|
*/
|
|
10
6
|
export declare function createListener(serenity: Serenity, moduleLoader: ModuleLoader): any;
|
|
11
7
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/listeners/messages/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAClD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAG7D
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/listeners/messages/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAClD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAC;AAG7D;;GAEG;AACH,wBAAgB,cAAc,CAAC,QAAQ,EAAE,QAAQ,EAAE,YAAY,EAAE,YAAY,GAAG,GAAG,CAKlF"}
|
|
@@ -3,11 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.createListener = void 0;
|
|
4
4
|
const cucumberMessagesListener = require("./CucumberMessagesListener");
|
|
5
5
|
/**
|
|
6
|
-
*
|
|
7
|
-
* Creates a listener for Cucumber.js v7.x and above
|
|
8
|
-
*
|
|
9
|
-
* @param serenity
|
|
10
|
-
* @param moduleLoader
|
|
6
|
+
* Creates a listener for Cucumber.js v7.x and above
|
|
11
7
|
*/
|
|
12
8
|
function createListener(serenity, moduleLoader) {
|
|
13
9
|
return cucumberMessagesListener(serenity, moduleLoader);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/listeners/messages/index.ts"],"names":[],"mappings":";;;AAEA,uEAAwE;AAExE
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/listeners/messages/index.ts"],"names":[],"mappings":";;;AAEA,uEAAwE;AAExE;;GAEG;AACH,SAAgB,cAAc,CAAC,QAAkB,EAAE,YAA0B;IACzE,OAAO,wBAAwB,CAC3B,QAAQ,EACR,YAAY,CACf,CAAC;AACN,CAAC;AALD,wCAKC"}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@serenity-js/cucumber",
|
|
3
|
-
"version": "3.25.
|
|
4
|
-
"description": "Serenity/JS adapter for
|
|
3
|
+
"version": "3.25.2",
|
|
4
|
+
"description": "Serenity/JS test runner adapter for seamless integration with any version of Cucumber.js, facilitating BDD-style test automation and leveraging Serenity/JS reporting capabilities",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Jan Molak",
|
|
7
7
|
"email": "jan.molak@smartcodeltd.co.uk",
|
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
},
|
|
46
46
|
"dependencies": {
|
|
47
47
|
"@cucumber/messages": "24.1.0",
|
|
48
|
-
"@serenity-js/core": "3.25.
|
|
48
|
+
"@serenity-js/core": "3.25.2",
|
|
49
49
|
"cli-table3": "0.6.5",
|
|
50
50
|
"gherkin": "5.1.0",
|
|
51
51
|
"tiny-types": "1.22.0"
|
|
@@ -73,5 +73,5 @@
|
|
|
73
73
|
"ts-node": "10.9.2",
|
|
74
74
|
"typescript": "5.2.2"
|
|
75
75
|
},
|
|
76
|
-
"gitHead": "
|
|
76
|
+
"gitHead": "98b68da1e04a8fcbb255dca509b7bc9c322a3b6b"
|
|
77
77
|
}
|
|
@@ -13,7 +13,7 @@ import type { OutputDescriptor, SerenityFormatterOutput } from './output';
|
|
|
13
13
|
* Allows for programmatic execution of Cucumber test scenarios.
|
|
14
14
|
*
|
|
15
15
|
* ## Learn more
|
|
16
|
-
* -
|
|
16
|
+
* - [`TestRunnerAdapter`](https://serenity-js.org/api/core-adapter/interface/TestRunnerAdapter/)
|
|
17
17
|
*
|
|
18
18
|
* @group Integration
|
|
19
19
|
*/
|
|
@@ -33,7 +33,7 @@ export class CucumberCLIAdapter implements TestRunnerAdapter {
|
|
|
33
33
|
}
|
|
34
34
|
|
|
35
35
|
/**
|
|
36
|
-
* Scenario success threshold for this test runner, calculated based on
|
|
36
|
+
* Scenario success threshold for this test runner, calculated based on [`CucumberConfig`](https://serenity-js.org/api/cucumber-adapter/interface/CucumberConfig/)
|
|
37
37
|
*/
|
|
38
38
|
successThreshold(): Outcome | { Code: number } {
|
|
39
39
|
return this.options.isStrict()
|
|
@@ -62,7 +62,7 @@ export class CucumberCLIAdapter implements TestRunnerAdapter {
|
|
|
62
62
|
/**
|
|
63
63
|
* Returns the number of loaded scenarios
|
|
64
64
|
*
|
|
65
|
-
* @throws
|
|
65
|
+
* @throws [`LogicError`](https://serenity-js.org/api/core/class/LogicError/)
|
|
66
66
|
* If called before `load`
|
|
67
67
|
*/
|
|
68
68
|
scenarioCount(): number {
|
|
@@ -42,7 +42,7 @@ export interface CucumberConfig {
|
|
|
42
42
|
* Enable/disable colors in output. Cucumber 1.x only!
|
|
43
43
|
* For Cucumber 2.x and above use `formatOptions: { colorsEnabled: false }`
|
|
44
44
|
*
|
|
45
|
-
* **Note** For Cucumber 2.x and above use the
|
|
45
|
+
* **Note** For Cucumber 2.x and above use the [`CucumberConfig.formatOptions`](https://serenity-js.org/api/cucumber-adapter/interface/CucumberConfig/#formatOptions) instead.
|
|
46
46
|
*
|
|
47
47
|
* #### Disable colors in output in Cucumber 1.x
|
|
48
48
|
*
|
|
@@ -67,7 +67,7 @@ export interface CucumberConfig {
|
|
|
67
67
|
* Step definitions and support files can be written in languages that transpile to JavaScript.
|
|
68
68
|
* To do set the `compiler` option to `<file_extension>:<module_name>`
|
|
69
69
|
*
|
|
70
|
-
* **NoteL** For Cucumber 4.x and above use the
|
|
70
|
+
* **NoteL** For Cucumber 4.x and above use the [`CucumberConfig.require`](https://serenity-js.org/api/cucumber-adapter/interface/CucumberConfig/#require) option instead.
|
|
71
71
|
*
|
|
72
72
|
* #### Enable TypeScript support in Cucumber 1.x - 3.x
|
|
73
73
|
* ```ts
|
|
@@ -126,13 +126,7 @@ export class CucumberOptions {
|
|
|
126
126
|
}
|
|
127
127
|
|
|
128
128
|
/**
|
|
129
|
-
*
|
|
130
|
-
* Converts camelCase option names to kebab-case.
|
|
131
|
-
*
|
|
132
|
-
* @param {string} option
|
|
133
|
-
* @returns {string}
|
|
134
|
-
*
|
|
135
|
-
* @private
|
|
129
|
+
* Converts camelCase option names to kebab-case.
|
|
136
130
|
*/
|
|
137
131
|
private asCliOptionName(option: string): string {
|
|
138
132
|
return option
|
package/src/index.ts
CHANGED
|
@@ -10,7 +10,7 @@ const version = loader.hasAvailable('@cucumber/cucumber')
|
|
|
10
10
|
: loader.versionOf('cucumber');
|
|
11
11
|
|
|
12
12
|
/**
|
|
13
|
-
* Registers a Cucumber reporter that emits
|
|
13
|
+
* Registers a Cucumber reporter that emits [Serenity/JS domain events](https://serenity-js.org/api/core-events/class/DomainEvent/)
|
|
14
14
|
* and informs Serenity/JS when test scenarios and Cucumber steps start, finish, and with what result.
|
|
15
15
|
*/
|
|
16
16
|
const listener: unknown = version.isAtLeast(new Version('7.0.0'))
|
|
@@ -3,11 +3,7 @@ import type { ModuleLoader } from '@serenity-js/core/lib/io';
|
|
|
3
3
|
import cucumberMessagesListener = require('./CucumberMessagesListener');
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
|
-
*
|
|
7
|
-
* Creates a listener for Cucumber.js v7.x and above
|
|
8
|
-
*
|
|
9
|
-
* @param serenity
|
|
10
|
-
* @param moduleLoader
|
|
6
|
+
* Creates a listener for Cucumber.js v7.x and above
|
|
11
7
|
*/
|
|
12
8
|
export function createListener(serenity: Serenity, moduleLoader: ModuleLoader): any {
|
|
13
9
|
return cucumberMessagesListener(
|