You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+18-1Lines changed: 18 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -18,7 +18,7 @@ Here you can see an example card for failed test results:
18
18
19
19
To use this reporter, you must have a Microsoft Teams webhook URL. You can create a webhook URL using the Microsoft Teams Power Automate connector or the Microsoft Teams incoming webhook functionality.
20
20
21
-
As the incoming webhook functionality will stop working on October 1, 2024, it is recommended to use the Power Automate connector functionality.
21
+
As the incoming webhook functionality will stop working on October 1, 2024 (extended to December 2025), it is recommended to use the Power Automate connector functionality.
22
22
23
23
> **Important**: You need to copy the `webhook URL` from the configuration, as you will need it to configure the reporter.
24
24
@@ -40,6 +40,11 @@ To create a Power Automate webhook for Microsoft Teams, you can follow these ste
40
40
- Click on the **Save** button
41
41
- Click on **When a Teams webhook request is received** and copy the **HTTP URL**
42
42
43
+
> [!WARNING]
44
+
> When using the PowerAutomate template, a template footer will automatically be included like: `<name> used a Workflow template to send this card. Get template`.
45
+
> You can remove this footer by creating a copy of the flow, and use the new one instead.
46
+
> You can find more information about this procedure in the following blog post: [How to remove "<Name> used a Workflow template to send this card. Get template"](https://docs.hetrixtools.com/microsoft-teams-how-to-remove-name-used-a-workflow-template-to-send-this-card-get-template/).
47
+
43
48
### Microsoft Teams incoming webhook (retiring October 1, 2024)
44
49
45
50
To use this reporter, you need to create an incoming webhook for your Microsoft Teams channel. You can find more information on how to do this in the [Microsoft documentation](https://learn.microsoft.com/en-us/microsoftteams/platform/webhooks-and-connectors/how-to/add-incoming-webhook?tabs=newteams%2Cdotnet#create-an-incoming-webhook).
@@ -97,6 +102,7 @@ The reporter supports the following configuration options:
97
102
|`enableEmoji`| Show an emoji based on the test status |`boolean`|`false`|`false`|
98
103
|`quiet`| Do not show any output in the console |`boolean`|`false`|`false`|
99
104
|`debug`| Show debug information |`boolean`|`false`|`false`|
105
+
|`shouldRun`| Conditional reporting |` Suite => boolean`|`false`|`true`|
100
106
101
107
### Mention users
102
108
@@ -128,6 +134,17 @@ The format can be either the full name and email (`"Full name <email>"`) or just
128
134
129
135
With the `linkToResultsUrl` option, you can provide a link to the test results. For example, you can view the test results on your CI/CD platform.
130
136
137
+
### Conditional reporting (shouldRun)
138
+
139
+
Example (report only from jenkins runs - project name set as 'dev__jenkins'):
140
+
```javascript
141
+
shouldRun: (suite) => {
142
+
if (suite.suites[0].project()?.name.includes('_jenkins')) returntrue
0 commit comments