flutter / flutter/flutter-intellij

Test configuration for all tests in directory does not allow debug mode

Open
#4,742 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
2k
Forks
356
Avg merge
1d 11h
Merged PRs (30d)
27

Description

Test scope is 'Test in file, filtered by name':
![Screen Shot 2020-08-05 at 10 09 41 AM](https://user-images.githubusercontent.com/6379305/89442689-162b5100-d704-11ea-8e24-827ed1eae5ac.png)

Test scope is 'All in directory':
![Screen Shot 2020-08-05 at 10 09 47 AM](https://user-images.githubusercontent.com/6379305/89442696-17f51480-d704-11ea-8d63-4e883386b59f.png)

## More context on this issue
Why this happens
- Using a test scope of directory means that running tests will be done through `DefaultRunProgramRunner` instead of `FlutterTestRunner`
- This is because `FlutterTestRunner` returns false for directory tests for either run mode (run or debug)
- There's no default runner for debugging, so that's why the debug button doesn't show up

What we'd like to have ideally
- Both run and debug run through `FlutterTestRunner` (or other custom runner) so that we can use `--start-paused` and have debugging for directory tests

Implementation steps
- Manage multiple observatory connections for one process handler (see `FlutterTestRunner::runInDebugger` and `Connector` class)
- Similarly, allow multiple `XDebugProcess`s for an `XDebugSession`

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.