Skip to content

Allow test selection by file:lineno #3224

Open
@blueyed

Description

@blueyed

pytest tests/test_foo.py:42 should run the (nearest) test at line 42 in tests/test_foo.py.

When it also ignores a trailing colon it would allow for easy copy'n'pasting from failures.

Via #5973:

To get a better overview of how it can work take a look at the Rspec documentation

Metadata

Metadata

Assignees

Labels

topic: selectionrelated to test selection from the command linetype: enhancementnew feature or API change, should be merged into features branch

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions