Skip to content

Hooks added as a side effect of a called function don't get cleaned up #34

@sarahsturgeon

Description

@sarahsturgeon

The test environment we create keeps track of hooks added with hook.Add and automatically cleans them up after the test completes.

However, if you call a function that calls hook.Add, they will not be tracked.

Is there a clever way of using setfenv (perhaps on a thread instead of a function?) that will let us accomplish this? Or should we just accept the fact that you need to clean up any hooks you indirectly create in your tests?

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestgood first issueGood for newcomershelp wantedExtra attention is neededquestionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions