Skip to main content

Posts

Showing posts with the label AdaptiveCards

Want to share Test Results to MS Teams using AdaptiveCards.io?

Steps to follow: Microsoft Teams WebHook: Follow this  https://docs.microsoft.com/en-us/microsoftteams/platform/webhooks-and-connectors/how-to/add-incoming-webhook to create a webhook. Capture the  URL you will get from Step # 5 from the above article for Posting the Results in MS teams. Select a design from https://adaptivecards.io/samples/ or you can take the one that I created here:  https://github.com/dgambhir01/AdaptiveCards/blob/main/src/main/java/listeners/ResultBuilder.java Now implement the Builder Class and a POJO Class. Sample code:  https://github.com/dgambhir01/AdaptiveCards/blob/main/src/main/java/listeners/CardBodyStructure.java Last but not least add a Listener Class to send Results on Finish. Sample code:  https://github.com/dgambhir01/AdaptiveCards/blob/main/src/main/java/listeners/ResultListener.java Now you can add the above TestNG Listener to your TestNG XML File and run your test cases.  After the Execution, you should see your t...