Skip to content

Multiplying tests should happen after -kΒ #15

@blueyed

Description

@blueyed

When used with -k to select only some specific tests, pytest still collects all tests, multiplied by the number passed to --count.

Therefore pytest --count=120 -x -k test_foo will collect the number of total tests times 120, which results in a lot of processing and memory usage.

I can imagine that pytest-repeat could be improved in this regard to only multiply the collected tests after -k was applied.

The workaround here is to specify the file containing the test, but that still multiplies the tests contained in this file.

platform linux -- Python 3.6.1, pytest-3.0.7, py-1.4.33, pluggy-0.4.0
cachedir: .cache
Django settings: velodrome.settings (from environment variable)
plugins: testmon-0.9.4, repeat-0.4.1, profiling-1.2.6, pdb-0.2.0, mock-1.6.0, django-3.1.2, catchlog-1.2.2, asyncio-0.5.0, pylama-7.3.3

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