mattermost-community / mattermost-plugin-todo

Mattermost plugin for tracking to do items
Apache License 2.0
67 stars 59 forks source link

[GH-124]: Integrating Playwright for E2E tests #228

Closed rahulsuresh-git closed 10 months ago

rahulsuresh-git commented 10 months ago

Summary

This PR introduces E2E testing for the Todo plugin using Playwright. It largely borrows from the implementation in the GitHub plugin https://github.com/mattermost/mattermost-plugin-github/blob/master/.github/workflows/playwright.yml. There are changes made to support the latest monorepo changes.

The tests themselves assert that the correct slash command suggestions are shown when you type /todo into the post text box.

Original PR https://github.com/mattermost/mattermost-plugin-todo/pull/231

Ticket Link

Fixes https://github.com/mattermost/mattermost-plugin-todo/issues/124

rahulsuresh-git commented 10 months ago

Hi @mickmister and @larkox, I've verified that the changes work by running a simple test that triggers the slash container popup when someone types /todo.

Here are the results:

image

Let me know if you have any concerns. I'd be happy to address.

rahulsuresh-git commented 10 months ago

This PR is ready for review.

codecov-commenter commented 10 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Comparison is base (8b25f12) 6.42% compared to head (e6af7c0) 6.42%.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #228 +/- ## ====================================== Coverage 6.42% 6.42% ====================================== Files 11 11 Lines 1712 1712 ====================================== Hits 110 110 Misses 1594 1594 Partials 8 8 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

mickmister commented 10 months ago

Awesome work on this @rahulsuresh-git!! It's incredible the effort you put into this and the result has already had a big impact on our team's direction on testing the plugin projects.

We had a past effort to introduce e2e tests to our plugin projects, though it was generally de-prioritized and left as a work-in-progress. Your efforts here to take that on and ensure a working framework has sparked momentum in our team to achieve better test confidence on each of the projects. Great work creating a solid foundation to build on top of 🚀 Thanks @rahulsuresh-git!

rahulsuresh-git commented 10 months ago

Thank you for the opportunity! @mickmister :)