diff --git a/docs/tephi/source/conf.py b/docs/tephi/source/conf.py index a436619..83c02c4 100644 --- a/docs/tephi/source/conf.py +++ b/docs/tephi/source/conf.py @@ -18,10 +18,10 @@ # ensure tephi is discoverable by rtd build environment root = pathlib.Path(__file__).absolute().parent.parent.parent.parent -os.environ["PYTHONPATH"] = str(root) -sys.path.insert(0, str(root)) +os.environ["PYTHONPATH"] = str(root) + "/src" +sys.path.insert(0, str(root) + "/src") -import tephi +from src import tephi # If extensions (or modules to document with autodoc) are in another directory, # add these directories to sys.path here. If the directory is relative to the diff --git a/setup.cfg b/setup.cfg index 65cf4f9..6760cd6 100644 --- a/setup.cfg +++ b/setup.cfg @@ -2,19 +2,19 @@ exclude = .git, docs, - tephi/tests/__init__.py + src/tephi/tests/__init__.py .eggs [tool:pytest] testpaths = - tephi/ + src/tephi/ markers = graphical: mark a test as a graphical test addopts = -ra -v --cov-config=.coveragerc - --cov=tephi + --cov=src/tephi --cov-report=term-missing --doctest-modules doctest_optionflags = NORMALIZE_WHITESPACE ELLIPSIS NUMBER diff --git a/tephi/__init__.py b/src/tephi/__init__.py similarity index 100% rename from tephi/__init__.py rename to src/tephi/__init__.py diff --git a/tephi/_constants.py b/src/tephi/_constants.py similarity index 100% rename from tephi/_constants.py rename to src/tephi/_constants.py diff --git a/tephi/etc/test_data/barbs.txt b/src/tephi/etc/test_data/barbs.txt similarity index 100% rename from tephi/etc/test_data/barbs.txt rename to src/tephi/etc/test_data/barbs.txt diff --git a/tephi/etc/test_data/comma_sep.txt b/src/tephi/etc/test_data/comma_sep.txt similarity index 100% rename from tephi/etc/test_data/comma_sep.txt rename to src/tephi/etc/test_data/comma_sep.txt diff --git a/tephi/etc/test_data/dews.txt b/src/tephi/etc/test_data/dews.txt similarity index 100% rename from tephi/etc/test_data/dews.txt rename to src/tephi/etc/test_data/dews.txt diff --git a/tephi/etc/test_data/temps.txt b/src/tephi/etc/test_data/temps.txt similarity index 100% rename from tephi/etc/test_data/temps.txt rename to src/tephi/etc/test_data/temps.txt diff --git a/tephi/isopleths.py b/src/tephi/isopleths.py similarity index 100% rename from tephi/isopleths.py rename to src/tephi/isopleths.py diff --git a/tephi/tests/__init__.py b/src/tephi/tests/__init__.py similarity index 100% rename from tephi/tests/__init__.py rename to src/tephi/tests/__init__.py diff --git a/tephi/tests/conftest.py b/src/tephi/tests/conftest.py similarity index 100% rename from tephi/tests/conftest.py rename to src/tephi/tests/conftest.py diff --git a/tephi/tests/idiff.py b/src/tephi/tests/idiff.py similarity index 100% rename from tephi/tests/idiff.py rename to src/tephi/tests/idiff.py diff --git a/tephi/tests/results/barbs.npz b/src/tephi/tests/results/barbs.npz similarity index 100% rename from tephi/tests/results/barbs.npz rename to src/tephi/tests/results/barbs.npz diff --git a/tephi/tests/results/dews.npz b/src/tephi/tests/results/dews.npz similarity index 100% rename from tephi/tests/results/dews.npz rename to src/tephi/tests/results/dews.npz diff --git a/tephi/tests/results/imagerepo.json b/src/tephi/tests/results/imagerepo.json similarity index 100% rename from tephi/tests/results/imagerepo.json rename to src/tephi/tests/results/imagerepo.json diff --git a/tephi/tests/results/temps.npz b/src/tephi/tests/results/temps.npz similarity index 100% rename from tephi/tests/results/temps.npz rename to src/tephi/tests/results/temps.npz diff --git a/tephi/tests/test_imagerepo.py b/src/tephi/tests/test_imagerepo.py similarity index 100% rename from tephi/tests/test_imagerepo.py rename to src/tephi/tests/test_imagerepo.py diff --git a/tephi/tests/test_tephigram.py b/src/tephi/tests/test_tephigram.py similarity index 100% rename from tephi/tests/test_tephigram.py rename to src/tephi/tests/test_tephigram.py diff --git a/tephi/transforms.py b/src/tephi/transforms.py similarity index 100% rename from tephi/transforms.py rename to src/tephi/transforms.py diff --git a/tox.ini b/tox.ini index 20d36bf..1d944c3 100644 --- a/tox.ini +++ b/tox.ini @@ -25,7 +25,7 @@ setenv = BUILDDIR = {toxinidir}/docs/_build conda_env = requirements/rtd.yml commands = - sphinx-apidoc -o "{env:DOCSDIR}/api" tephi tephi/tests + sphinx-apidoc -o "{env:DOCSDIR}/api" src/tephi src/tephi/tests sphinx-build -W --keep-going -b html -d "{env:BUILDDIR}/doctrees" "{env:DOCSDIR}" "{env:BUILDDIR}/html" {posargs} # when running the doctests, also check that any snippets in the # docs are representative of the module output