Skip to content

Commit 59ed86b

Browse files
ludeknovyLudek Novydavidjgoss
authored
bringing back v6/5 props (cucumber#1732)
* bringing back v6/5 props * changelog update * Update CHANGELOG.md Co-authored-by: David Goss <[email protected]> Co-authored-by: Ludek Novy <[email protected]> Co-authored-by: David Goss <[email protected]>
1 parent 5c4aa1c commit 59ed86b

File tree

2 files changed

+13
-0
lines changed

2 files changed

+13
-0
lines changed

CHANGELOG.md

+1
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ Please see [CONTRIBUTING.md](https://github.com/cucumber/cucumber/blob/master/CO
2626

2727
* Prevent duplicate scenario execution where the same feature is targeted in multiple line expressions ([#1706](https://github.com/cucumber/cucumber-js/issues/1706))
2828
* Fixed reports banner to point to [new docs](https://cucumber.io/docs/cucumber/environment-variables/) about environment variables
29+
* Re-add color functions for use with custom formatters [1582](https://github.com/cucumber/cucumber-js/issues/1582)
2930
* IParameterTypeDefinition regexp fix [1702](https://github.com/cucumber/cucumber-js/issues/1702)
3031

3132
## [7.3.0] (2021-06-17)

src/formatter/get_color_fns.ts

+12
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@ export interface IColorFns {
99
forStatus: (status: TestStepResultStatus) => IColorFn
1010
location: IColorFn
1111
tag: IColorFn
12+
diffAdded: IColorFn
13+
diffRemoved: IColorFn
14+
errorMessage: IColorFn
15+
errorStack: IColorFn
1216
}
1317

1418
export default function getColorFns(enabled: boolean): IColorFns {
@@ -27,6 +31,10 @@ export default function getColorFns(enabled: boolean): IColorFns {
2731
},
2832
location: colors.gray.bind(colors),
2933
tag: colors.cyan.bind(colors),
34+
diffAdded: colors.green.bind(colors),
35+
diffRemoved: colors.red.bind(colors),
36+
errorMessage: colors.red.bind(colors),
37+
errorStack: colors.grey.bind(colors),
3038
}
3139
} else {
3240
return {
@@ -35,6 +43,10 @@ export default function getColorFns(enabled: boolean): IColorFns {
3543
},
3644
location: (x) => x,
3745
tag: (x) => x,
46+
diffAdded: (x) => x,
47+
diffRemoved: (x) => x,
48+
errorMessage: (x) => x,
49+
errorStack: (x) => x,
3850
}
3951
}
4052
}

0 commit comments

Comments
 (0)