ci-slack-reporter 1.0.10 → 1.0.11

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 (2) hide show
  1. package/index.js +7 -7
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -44,7 +44,7 @@ class MyReporter {
44
44
 
45
45
  runner
46
46
  .once(EVENT_RUN_BEGIN, () => {
47
- const filename = filename;
47
+ const filename = runner.suite?.file;
48
48
  console.log(`⚡runner ${filename}`);
49
49
 
50
50
  out[filename] = {
@@ -128,12 +128,12 @@ class MyReporter {
128
128
 
129
129
  if (stats.failures) {
130
130
  out[filename].attachments[0].blocks = out[filename].attachments[0].blocks.filter(el => {
131
- return !el?.text?.text?.startsWith(":white")
132
- })
133
- splitIfBlocksLimit(out[filename]).forEach((part) => {
134
- fails_only_webhook?.send(part);
135
- });
136
- }
131
+ return !el?.text?.text?.startsWith(":white")
132
+ })
133
+ splitIfBlocksLimit(out[filename]).forEach((part) => {
134
+ fails_only_webhook?.send(part);
135
+ });
136
+ }
137
137
  });
138
138
  }
139
139
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ci-slack-reporter",
3
- "version": "1.0.10",
3
+ "version": "1.0.11",
4
4
  "description": "Mocha/Cypress reporter to post tests results directly to Slack",
5
5
  "main": "index.js",
6
6
  "scripts": {