Skip to content

Have render call cleanup #428

Closed
Closed
@Gpx

Description

@Gpx

Describe the feature you'd like:

Right now we have to call cleanup before each test. This tends to be confusing for beginners especially if they come from other libraries (Enzyme) that do not need this step. It would be good if render could call cleanup automatically.

Suggested implementation:

I didn't dig into the code too much but it should be as easy as having render call cleanup as the first thing it does.

Describe alternatives you've considered:

I'm trying to think about a use-case where you might want to run two renders in the same test or where you might want to manually run cleanup—which would invalidate this idea—but can't come up with anything.

Teachability, Documentation, Adoption, Migration Strategy:

We would have to remove the documentation about cleanup. Potentially we would have to introduce a breaking change.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions