@serenity-js/console-reporter 3.36.2 → 3.37.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/CHANGELOG.md +8 -0
- package/README.md +103 -71
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,14 @@
|
|
|
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.37.0](https://github.com/serenity-js/serenity-js/compare/v3.36.2...v3.37.0) (2025-12-02)
|
|
7
|
+
|
|
8
|
+
**Note:** Version bump only for package @serenity-js/console-reporter
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
6
14
|
## [3.36.2](https://github.com/serenity-js/serenity-js/compare/v3.36.1...v3.36.2) (2025-11-26)
|
|
7
15
|
|
|
8
16
|
**Note:** Version bump only for package @serenity-js/console-reporter
|
package/README.md
CHANGED
|
@@ -1,84 +1,87 @@
|
|
|
1
|
-
|
|
1
|
+
## Serenity/JS Console Reporter
|
|
2
|
+
|
|
3
|
+
[](https://badge.fury.io/js/%40serenity-js%2Fconsole-reporter)
|
|
4
|
+
[](https://github.com/serenity-js/serenity-js/actions)
|
|
5
|
+
[](https://qlty.sh/gh/serenity-js/projects/serenity-js)
|
|
6
|
+
[](https://qlty.sh/gh/serenity-js/projects/serenity-js)
|
|
7
|
+
[](https://github.com/serenity-js/serenity-js/graphs/contributors)
|
|
8
|
+
[](https://snyk.io/test/npm/@serenity-js/console-reporter)
|
|
9
|
+
[](https://github.com/serenity-js/serenity-js)
|
|
2
10
|
|
|
3
11
|
[](https://www.linkedin.com/company/serenity-js)
|
|
4
12
|
[](https://www.youtube.com/@serenity-js)
|
|
5
13
|
[](https://matrix.to/#/#serenity-js:gitter.im)
|
|
6
14
|
[](https://github.com/sponsors/serenity-js)
|
|
7
15
|
|
|
8
|
-
[
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
⭐️ Get started with Serenity/JS!
|
|
12
|
-
- [Serenity/JS web testing tutorial](https://serenity-js.org/handbook/web-testing/your-first-web-scenario)
|
|
13
|
-
- [Serenity/JS Handbook](https://serenity-js.org/handbook)
|
|
14
|
-
- [API documentation](https://serenity-js.org/api/)
|
|
15
|
-
- [Serenity/JS Project Templates](https://serenity-js.org/handbook/project-templates/)
|
|
16
|
-
|
|
17
|
-
👋 Join the Serenity/JS Community!
|
|
18
|
-
- Meet other Serenity/JS developers and maintainers on the [Serenity/JS Community chat channel](https://matrix.to/#/#serenity-js:gitter.im),
|
|
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/community/contributing/),
|
|
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)!
|
|
16
|
+
[`@serenity-js/console-reporter`](https://serenity-js.org/api/console-reporter/)
|
|
17
|
+
logs test progress and results to the console in a readable format.
|
|
22
18
|
|
|
23
|
-
##
|
|
19
|
+
## Features
|
|
24
20
|
|
|
25
|
-
|
|
26
|
-
|
|
21
|
+
- Colour-coded console output for test results
|
|
22
|
+
- Summaries of test runs and failures
|
|
23
|
+
- Works with all [supported test runners](https://serenity-js.org/handbook/test-runners/)
|
|
27
24
|
|
|
25
|
+
See example output in the [Serenity/JS Handbook](https://serenity-js.org/handbook/reporting/console-reporter/).
|
|
28
26
|
|
|
29
|
-
|
|
27
|
+
## Installation
|
|
30
28
|
|
|
31
29
|
```sh
|
|
32
30
|
npm install --save-dev @serenity-js/core @serenity-js/console-reporter
|
|
33
31
|
```
|
|
34
32
|
|
|
33
|
+
See the [Serenity/JS Installation Guide](https://serenity-js.org/handbook/installation/).
|
|
35
34
|
|
|
36
|
-
|
|
35
|
+
### Windows
|
|
37
36
|
|
|
38
37
|
If you're on Windows, consider using [Windows Terminal](https://github.com/microsoft/terminal)
|
|
39
38
|
instead of `cmd.exe` to benefit from the colour output.
|
|
40
39
|
|
|
41
|
-
|
|
40
|
+
## Quick Start
|
|
42
41
|
|
|
43
|
-
To
|
|
42
|
+
To use the console reporter in your Serenity/JS project, install the
|
|
43
|
+
[`@serenity-js/console-reporter`](https://serenity-js.org/api/console-reporter/) package
|
|
44
|
+
and configure the reporter as part of the `Stage` crew using your test runner's configuration file.
|
|
44
45
|
|
|
45
|
-
|
|
46
|
-
- via `playwright.config.ts`, if you're using Serenity/JS with [Playwright Test](https://serenity-js.org/api/playwright-test)
|
|
47
|
-
- via `wdio.conf.ts`, if you're using Serenity/JS with [WebdriverIO](https://serenity-js.org/api/playwright-test)
|
|
48
|
-
- via `protractor.conf.js`, if you're using Serenity/JS with [Protractor](https://serenity-js.org/api/protractor)
|
|
49
|
-
- or programmatically.
|
|
46
|
+
### Usage with Playwright Test
|
|
50
47
|
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
Learn more about using [Serenity/JS with Playwright Test](https://serenity-js.org/api/playwright-test).
|
|
48
|
+
When integrating Serenity/JS with Playwright Test,
|
|
49
|
+
use the following configuration in your `playwright.config.ts` file to enable the console reporter:
|
|
54
50
|
|
|
55
51
|
```typescript
|
|
56
52
|
// playwright.config.ts
|
|
57
|
-
import
|
|
53
|
+
import { defineConfig, devices } from '@playwright/test';
|
|
54
|
+
import { SerenityFixtures, SerenityWorkerFixtures } from '@serenity-js/playwright-test';
|
|
55
|
+
|
|
56
|
+
export default defineConfig<SerenityFixtures, SerenityWorkerFixtures>({
|
|
58
57
|
|
|
59
|
-
const config: PlaywrightTestConfig = {
|
|
60
58
|
reporter: [
|
|
61
|
-
[
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
59
|
+
[
|
|
60
|
+
path.resolve(__dirname, '../../packages/playwright-test'), // '@serenity-js/playwright-test'
|
|
61
|
+
{
|
|
62
|
+
crew: [
|
|
63
|
+
// Use console reporter with default settings
|
|
64
|
+
'@serenity-js/console-reporter',
|
|
65
|
+
|
|
66
|
+
// Alternatively, use console reporter
|
|
67
|
+
// with a theme for 'dark', 'light' or 'mono' terminals
|
|
68
|
+
// [ '@serenity-js/console-reporter', { theme: 'auto' } ]
|
|
69
|
+
],
|
|
70
|
+
},
|
|
71
|
+
],
|
|
70
72
|
],
|
|
71
73
|
|
|
72
74
|
// Other configuration omitted for brevity
|
|
73
75
|
// For details, see https://playwright.dev/docs/test-configuration
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
export default config
|
|
76
|
+
});
|
|
77
77
|
```
|
|
78
78
|
|
|
79
|
-
|
|
79
|
+
Learn more about using [Serenity/JS with Playwright Test](https://serenity-js.org/handbook/test-runners/playwright-test/).
|
|
80
80
|
|
|
81
|
-
|
|
81
|
+
### Usage with WebdriverIO
|
|
82
|
+
|
|
83
|
+
When integrating Serenity/JS with WebdriverIO,
|
|
84
|
+
use the following configuration in your `wdio.conf.ts` file to enable the console reporter:
|
|
82
85
|
|
|
83
86
|
```typescript
|
|
84
87
|
// wdio.conf.ts
|
|
@@ -91,11 +94,12 @@ export const config: WebdriverIOConfig = {
|
|
|
91
94
|
|
|
92
95
|
serenity: {
|
|
93
96
|
crew: [
|
|
94
|
-
// console reporter with default settings
|
|
97
|
+
// Use console reporter with default settings
|
|
95
98
|
'@serenity-js/console-reporter',
|
|
96
99
|
|
|
97
|
-
//
|
|
98
|
-
//
|
|
100
|
+
// Alternatively, use console reporter
|
|
101
|
+
// with a theme for 'dark', 'light' or 'mono' terminals
|
|
102
|
+
// [ '@serenity-js/console-reporter', { theme: 'auto' } ]
|
|
99
103
|
]
|
|
100
104
|
},
|
|
101
105
|
|
|
@@ -104,9 +108,12 @@ export const config: WebdriverIOConfig = {
|
|
|
104
108
|
}
|
|
105
109
|
```
|
|
106
110
|
|
|
107
|
-
|
|
111
|
+
Learn more about using [Serenity/JS with WebdriverIO](https://serenity-js.org/api/webdriverio).
|
|
108
112
|
|
|
109
|
-
|
|
113
|
+
### Usage with Protractor
|
|
114
|
+
|
|
115
|
+
When integrating Serenity/JS with Protractor,
|
|
116
|
+
use the following configuration in your `protractor.conf.js` file to enable the console reporter:
|
|
110
117
|
|
|
111
118
|
```javascript
|
|
112
119
|
// protractor.conf.js
|
|
@@ -118,11 +125,12 @@ exports.config = {
|
|
|
118
125
|
|
|
119
126
|
serenity: {
|
|
120
127
|
crew: [
|
|
121
|
-
// console reporter with default settings
|
|
128
|
+
// Use console reporter with default settings
|
|
122
129
|
'@serenity-js/console-reporter',
|
|
123
130
|
|
|
124
|
-
//
|
|
125
|
-
//
|
|
131
|
+
// Alternatively, use console reporter
|
|
132
|
+
// with a theme for 'dark', 'light' or 'mono' terminals
|
|
133
|
+
// [ '@serenity-js/console-reporter', { theme: 'auto' } ]
|
|
126
134
|
]
|
|
127
135
|
},
|
|
128
136
|
|
|
@@ -130,9 +138,15 @@ exports.config = {
|
|
|
130
138
|
}
|
|
131
139
|
```
|
|
132
140
|
|
|
133
|
-
|
|
141
|
+
Learn more about using [Serenity/JS with Protractor](https://serenity-js.org/api/protractor).
|
|
142
|
+
|
|
143
|
+
### Programmatic configuration
|
|
134
144
|
|
|
135
|
-
|
|
145
|
+
When integrating Serenity/JS with a custom test runner setup, or using it programmatically,
|
|
146
|
+
use the [`Serenity.configure`](https://serenity-js.org/api/core/class/Serenity/#configure) method,
|
|
147
|
+
or the standalone [`configure`](https://serenity-js.org/api/core/function/configure/) function
|
|
148
|
+
to pass the [configuration object](https://serenity-js.org/api/core/class/SerenityConfig/)
|
|
149
|
+
that includes the `ConsoleReporter` as part of the `crew`.
|
|
136
150
|
|
|
137
151
|
```typescript
|
|
138
152
|
import { configure } from '@serenity-js/core'
|
|
@@ -145,25 +159,43 @@ configure({
|
|
|
145
159
|
})
|
|
146
160
|
```
|
|
147
161
|
|
|
148
|
-
|
|
162
|
+
### Changing the colour theme
|
|
149
163
|
|
|
150
|
-
|
|
151
|
-
to learn
|
|
164
|
+
See the [`ConsoleReporter` API docs](https://serenity-js.org/api/console-reporter/class/ConsoleReporter)
|
|
165
|
+
to learn about the supported colour themes.
|
|
152
166
|
|
|
153
|
-
##
|
|
167
|
+
## Documentation
|
|
154
168
|
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
169
|
+
- [API Reference](https://serenity-js.org/api/)
|
|
170
|
+
- [Screenplay Pattern Guide](https://serenity-js.org/handbook/design/screenplay-pattern/)
|
|
171
|
+
- [Serenity/JS Project Templates](https://serenity-js.org/handbook/project-templates/)
|
|
172
|
+
- [Tutorial: First Web Scenario](https://serenity-js.org/handbook/tutorials/your-first-web-scenario/)
|
|
173
|
+
- [Tutorial: First API Scenario](https://serenity-js.org/handbook/tutorials/your-first-api-scenario/)
|
|
159
174
|
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
175
|
+
## Contributing
|
|
176
|
+
|
|
177
|
+
Contributions of all kinds are welcome! Get started with the [Contributing Guide](https://serenity-js.org/community/contributing/).
|
|
178
|
+
|
|
179
|
+
## Community
|
|
180
|
+
|
|
181
|
+
- [Community Chat](https://matrix.to/#/#serenity-js:gitter.im)
|
|
182
|
+
- [Discussions Forum](https://github.com/orgs/serenity-js/discussions)
|
|
183
|
+
- Visit the [💡How to... ?](https://github.com/orgs/serenity-js/discussions/categories/how-to) section for answers to common questions
|
|
184
|
+
|
|
185
|
+
If you enjoy using Serenity/JS, make sure to star ⭐️ [Serenity/JS on GitHub](https://github.com/serenity-js/serenity-js) to help others discover the framework!
|
|
186
|
+
|
|
187
|
+
## License
|
|
188
|
+
|
|
189
|
+
The Serenity/JS code base is licensed under the [Apache-2.0](https://opensource.org/license/apache-2-0) license,
|
|
190
|
+
while its documentation and the [Serenity/JS Handbook](https://serenity-js.org/handbook/) are licensed under the [Creative Commons BY-NC-SA 4.0 International](https://creativecommons.org/licenses/by-nc-sa/4.0/).
|
|
191
|
+
|
|
192
|
+
See the [Serenity/JS License](https://serenity-js.org/legal/license/).
|
|
193
|
+
|
|
194
|
+
## Support
|
|
164
195
|
|
|
165
|
-
|
|
196
|
+
Support ongoing development through [GitHub Sponsors](https://github.com/sponsors/serenity-js). Sponsors gain access to [Serenity/JS Playbooks](https://github.com/serenity-js/playbooks)
|
|
197
|
+
and priority help in the [Discussions Forum](https://github.com/orgs/serenity-js/discussions).
|
|
166
198
|
|
|
167
|
-
|
|
199
|
+
For corporate sponsorship or commercial support, please contact [Jan Molak](https://www.linkedin.com/in/janmolak/).
|
|
168
200
|
|
|
169
|
-
[](https://github.com/sponsors/serenity-js)
|
|
201
|
+
[](https://github.com/sponsors/serenity-js).
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@serenity-js/console-reporter",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.37.0",
|
|
4
4
|
"description": "Serenity/JS console reporter that displays test results directly in the standard output",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Jan Molak",
|
|
@@ -49,7 +49,7 @@
|
|
|
49
49
|
"node": "^20 || ^22 || ^24"
|
|
50
50
|
},
|
|
51
51
|
"dependencies": {
|
|
52
|
-
"@serenity-js/core": "3.
|
|
52
|
+
"@serenity-js/core": "3.37.0",
|
|
53
53
|
"chalk": "4.1.2",
|
|
54
54
|
"tiny-types": "1.24.3"
|
|
55
55
|
},
|
|
@@ -63,5 +63,5 @@
|
|
|
63
63
|
"ts-node": "10.9.2",
|
|
64
64
|
"typescript": "5.9.3"
|
|
65
65
|
},
|
|
66
|
-
"gitHead": "
|
|
66
|
+
"gitHead": "dae146cd99a04f09b5926fb9d3205af562fa2927"
|
|
67
67
|
}
|