Skip to content

Parallelism guide/FAQ #272

Open
Open
@jnm2

Description

@jnm2

We've seen a few examples of folks asking why parallelism isn't working for them and it turns out that they're not realizing that they're sharing mutable state between threads. Sometimes it's something global and static, sometimes it's mutable fixture instance state because they expect a new fixture instance per test case. It would be good to provide examples of how to keep state separated, and what not to do (SetUp/TearDown), and why.

Here's an overly-complex example for a real-world project where I refactored from SetUp/TearDown toa parallel-safe solution: nunit/nunit#2105 (comment)

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