Skip to content

Tests should import from the package, not internal modules #38

@dannywillems

Description

@dannywillems

Problem

Tests import from internal modules instead of the public package API:

  • `from leakix.client import Scope` instead of `from leakix import Scope`
  • `from leakix.field import ...` instead of `from leakix import ...`
  • `from leakix.plugin import Plugin` instead of `from leakix import Plugin`
  • `from leakix.query import ...` instead of `from leakix import ...`
  • `from leakix.response import ...` instead of `from leakix import ...`

This applies to `test_client.py`, `test_query.py`, and `test_response.py`.

Solution

  • Change all test imports to use `from leakix import ...`
  • This also validates that `init.py` correctly re-exports everything

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