Skip to content

intellij_test is not hermetic #16339

Closed
Closed

Description

@tvolkert

Added in #16198

This test isn't hermetic and is subject to flakiness. We try to ensure that all new tests are hermetic by using MemoryFileSystem, FakePlatform, and a mocked ProcessManager where need be (using context overrides).

Activity

  1. added
    a: tests"flutter test", flutter_test, or one of our tests
    toolAffects the "flutter" command-line tool. See also t: labels.
    on Apr 7, 2018
  2. scheglov commented on Apr 7, 2018

    @scheglov
    Contributor
    1. I copied these tests from doctor_test.dart, which does not use overrides. Or do I miss them?

    2. These tests check presence and content of several jars, which we have in physical file system. How is this situation usually solved Flutter tests? It seems that copying them into MemoryFileSystem will not make them more hermetic, will it? Hm... Maybe I should instead just create jars inside of the test? Should not be too hard, we need just META-INF/plugin.xml in these jars.

  3. tvolkert commented on Apr 7, 2018

    @tvolkert
    ContributorAuthor

    I copied these tests from doctor_test.dart, which does not use overrides

    Ah, makes sense - doctor_test.dart is blacklisted in Google because it's not hermetic 😄

    Yeah, creating jars inside the test would work.

    If this is meant to be more of an integration test, then we can leave it as-is and just blacklist it within Google. It looks like it's meant to be more of a unit test though.

  4. github-actions commented on Sep 3, 2021

    @github-actions

    This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

  5. locked as resolved and limited conversation to collaborators on Sep 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

a: tests"flutter test", flutter_test, or one of our testsc: flakeTests that sometimes, but not always, incorrectly passtoolAffects the "flutter" command-line tool. See also t: labels.

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions