Skip to content

Request: Add notes about where to put unit tests #492

Open
@kevinarpe

Description

@kevinarpe

I did some Googling. None of the pages have very good explanations of where to put your unit test files.

Also, AFAIK (I am a Python newbiew) there are some drawbacks to <project_root>/test/ about importing. Might need to modify PYTHONPATH during unit test runs.

Also, please talk about why init.py is important for unit tests. A few places recommend it... but I thought it was dead in Python3.

Ref: http://pytest.org/latest/goodpractises.html
Ref: http://stackoverflow.com/questions/5341006/where-should-i-put-tests-when-packaging-python-modules
Ref: http://stackoverflow.com/questions/61151/where-do-the-python-unit-tests-go

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