Skip to content

Test order affecting reproducibility #20

Description

@FedericoCeratto

partition_tests() assign tests to parallel workers based on previous timing.
It would be useful to be able to assign the tests pseudorandomly:

  1. Occasionally tests might succeed or fail based on their execution order due to imperfect test isolation. Being able to run a test suite multiple times in different order would help to spot this issue.

  2. In order to ensure reproducibility, it should be possible to run the tests in the same order every time by setting a fixed random.seed(). Currently testr does not guarantee constant order.

  3. The test order should not be dependent on the host where the tests are run from. Tests are assigned based on previous timing on the same host and this can lead to false negatives. With randomization, the order should be a function of a random seed value and the number of workers.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions