Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add resource leak detection in test suite #7

Open
kostaleonard opened this issue Jun 11, 2022 · 0 comments
Open

Add resource leak detection in test suite #7

kostaleonard opened this issue Jun 11, 2022 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@kostaleonard
Copy link
Owner

kostaleonard commented Jun 11, 2022

I am new to Flutter, so this may not be an actual issue. I am concerned about potential memory (or other resource) leaks when, for example, a developer fails to call dispose() on objects referenced in a State object during the latter's disposal (see below). Can we add unit tests or a tool in CI/CD that will check for leaks?

See this flutter devtools issue for more info.

@override
  void dispose() {
    //Did I remember to dispose() everything?
    _textEditingController.dispose();
    _textFieldFocusNode.dispose();
    super.dispose();
  }
@kostaleonard kostaleonard added the enhancement New feature or request label Jun 11, 2022
@kostaleonard kostaleonard added this to the Second release milestone Jun 11, 2022
@kostaleonard kostaleonard self-assigned this Jun 11, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant