ni / nimble

The NI Nimble Design System
https://nimble.ni.dev
MIT License
32 stars 8 forks source link

Set up Blazor end-to-end tests #705

Closed m-akinc closed 7 months ago

m-akinc commented 2 years ago

🧹 Tech Debt

We should have infrastructure (presumably Playwright) for running e2e tests in order to fill testing gaps that are difficult to test via unit tests and Chromatic. This came up in the context of writing unit tests for the Nimble dialog's Blazor integration. The Blazor implementation of the dialog calls js using the JSRuntime, but BUnit tests don't support that. This made it impossible to test that part of the Blazor implementation.

Tasks

rajsite commented 2 years ago

@m-akinc can we make a separate issue to track the testing we need for the dialog when this issue to set-up infrastructure is addressed?

jattasNI commented 1 year ago

@atmgrifter00 can you update this tech debt item with any info/links/lessons learned from when you investigated it in your CI week?

atmgrifter00 commented 1 year ago

I got as far as creating a branch that has the Playwright infrastructure set up for Blazor, with a dummy test. However, at the moment, the PlaywrightFixture test fixture class isn't being called to properly set up the local run with the right Chromium version to run. Some investigation is needed to figure out what is missing. My guess is that there is only a little more work needed to get to where we can write a component e2e test in Blazor.

jattasNI commented 7 months ago

Renamed from "Set up end-to-end tests" to focus specifically on Blazor, which is now done (other than the follow up items tracked in separate issues). That's complete so I'll close the issue.

We've talked about adding similar Playwright infrastructure for nimble-components but don't have a specific prioritized use case in mind yet so we'll leave that untracked for now.