aspire icon indicating copy to clipboard operation
aspire copied to clipboard

Add playwright test for changing theme

Open adamint opened this issue 1 year ago • 1 comments

Aspire.Hosting.Tests/Dashboard may not be the best place to put this test long-term. I made it local only for now.

I was unable to access the dashboard frontend from a browser when trying the approach in Aspire.Dashboard.Tests of just creating the dashboard frontend app - it would not connect. If anyone has an idea why that might be, I'm all ears.

I also ran into gRPC issues after orchestrating. Also seeking feedback on that, but in the meantime I injected a mock dashboard service so that there is no grpc connection.

Microsoft Reviewers: Open in CodeFlow

adamint avatar May 10 '24 20:05 adamint

FYI, I'm adding some playwright based tests in https://github.com/dotnet/aspire/pull/3270 . But in that I'm using dotnet run to start up a real app, and then interact with it.

This waits for the dashboard to become available, and uses resiliency to handle retries - https://github.com/radical/aspire/blob/5a900f1f44018a84e6741c45c4d632a1b6e35090/tests/Shared/WorkloadTesting/AspireProject.cs#L408-L427 .

And this connects with playwright, and verifies that the expected resources show up on the dashboard.

radical avatar May 10 '24 22:05 radical

Was this closed by accident?

kvenkatrajan avatar May 21 '24 18:05 kvenkatrajan

@kvenkatrajan we are going to use Ankit’s e2e infrastructure so 90% of this pr content will be replaced :)

adamint avatar May 21 '24 18:05 adamint

thanks for working together on this, sounds like we'll end up with a single infrastructure and it will be easier for everyone.

(when you have your new PR could you check whether any of the feedback above still applies?)

danmoseley avatar May 22 '24 17:05 danmoseley