Skip to content

fixture.destroy() not called in cleanup #240

Closed
@Lukas-Kullmann

Description

@Lukas-Kullmann

Hey there, I ran into an issue that I could fix by calling fixture.destroy() at the end of my test. The details are not really important here.

Apparently, the cleanup function in projects/testing-library/src/lib/testing-library.ts only removes the elements from the dom. It does not destroy the fixture.

Is there a reason for that? I think destroying the fixture at the end of each test is a good idea since it also destroys the components which might free quite some memory in most cases. And I can also not think of any use case where you would not want to destroy the fixture at the end of a test.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions