Skip to content

fix: resource management issues - empty Dispose and missing nullability #4858

@thomhurst

Description

@thomhurst

Description

Empty Dispose in EventReceiverOrchestrator.cs (Lines 550-553)

public void Dispose() { /* No longer need to dispose... */ }

Class implements IDisposable but has no cleanup logic. Should either remove the interface or document why it's retained.

Missing Nullability Annotations in PropertyInjector.cs

Methods like InjectPropertiesRecursiveAsync accept TestContextEvents events without ? nullability, but line 105 checks if (events == null). The contract is unclear — parameter should be marked nullable or validated with ArgumentNullException.

Suggested Fix

  • Remove IDisposable from EventReceiverOrchestrator if no cleanup is needed
  • Add consistent nullability annotations to PropertyInjector parameters

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinggood first issueGood for newcomershelp wantedExtra attention is needed

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions