devtools icon indicating copy to clipboard operation
devtools copied to clipboard

Add a regression test for DevTools extensions connecting to Dart CLI apps

Open kenzieschmoll opened this issue 2 years ago • 2 comments

Fix was here: https://github.com/flutter/devtools/pull/6993.

To add testing for this, we need to add an integration test that spawns a Dart CLI app and connects to DevTools to load extensions. Our current test coverage just tests a Flutter app.

kenzieschmoll avatar Dec 20 '23 19:12 kenzieschmoll

@kenzieschmoll I see one integration test at packages/devtools_extensions/integration_test (simulated_environment_test.dart). Is this where we should add this new integration test? It looks like we could use the same TestDevToolsExtension, and just test it against a different app, a Dart app?

I can't actually find what app it is testing against. Is that sort of the new code we need? Does "simulated environment" mean "no app" 😅 ?

srawlins avatar May 02 '25 20:05 srawlins

I think we'd actually want to add another test like this one: https://github.com/flutter/devtools/blob/master/packages/devtools_app/integration_test/test/live_connection/devtools_extensions_test.dart. However, we first need to address this issue (https://github.com/flutter/devtools/issues/7748) which would add support for our integration tests to actually start the DevTools server. We added support for running a debug build of DevTools with the server here: https://github.com/flutter/devtools/issues/6486, but this may need some work to wire up to the integration testing framework since it expects DevTools to be able to run with Flutter driver. It should be possible though.

kenzieschmoll avatar May 06 '25 15:05 kenzieschmoll