diff --git a/.github/workflows/run_all_tests.yml b/.github/workflows/run_all_tests.yml index 67a645037..def51537f 100644 --- a/.github/workflows/run_all_tests.yml +++ b/.github/workflows/run_all_tests.yml @@ -233,7 +233,7 @@ jobs: - name: Install run dependencies run: | - pip install -e . + pip install . pip list - name: Conda reporting diff --git a/.github/workflows/run_coverage.yml b/.github/workflows/run_coverage.yml index 7a18e5068..a72a05e73 100644 --- a/.github/workflows/run_coverage.yml +++ b/.github/workflows/run_coverage.yml @@ -55,18 +55,18 @@ jobs: - name: Install package run: | - python -m pip install -e . # must install in editable mode for coverage to find sources + python -m pip install . python -m pip list - name: Run tests and generate coverage report run: | - pytest --cov - python -m coverage xml # codecov uploader requires xml format - python -m coverage report -m + # coverage is configured in pyproject.toml + pytest --cov --cov-report=xml --cov-report=term # codecov uploader requires xml format - name: Upload coverage to Codecov uses: codecov/codecov-action@v4 with: fail_ci_if_error: true + file: ./coverage.xml env: CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} diff --git a/.github/workflows/run_hdmf_zarr_tests.yml b/.github/workflows/run_hdmf_zarr_tests.yml index ecfdeaeeb..5e76711af 100644 --- a/.github/workflows/run_hdmf_zarr_tests.yml +++ b/.github/workflows/run_hdmf_zarr_tests.yml @@ -32,8 +32,7 @@ jobs: git clone https://github.com/hdmf-dev/hdmf-zarr.git --recurse-submodules cd hdmf-zarr python -m pip install -r requirements-dev.txt # do not install the pinned install requirements - # must install in editable mode for coverage to find sources - python -m pip install -e . # this will install a different version of hdmf from the current one + python -m pip install . # this will install a different version of hdmf from the current one cd .. python -m pip uninstall -y hdmf # uninstall the other version of hdmf python -m pip install . # reinstall current branch of hdmf diff --git a/.github/workflows/run_pynwb_tests.yml b/.github/workflows/run_pynwb_tests.yml index bf3f32343..1a714ed9f 100644 --- a/.github/workflows/run_pynwb_tests.yml +++ b/.github/workflows/run_pynwb_tests.yml @@ -32,8 +32,7 @@ jobs: git clone https://github.com/NeurodataWithoutBorders/pynwb.git --recurse-submodules cd pynwb python -m pip install -r requirements-dev.txt # do not install the pinned install requirements - # must install in editable mode for coverage to find sources - python -m pip install -e . # this will install a different version of hdmf from the current one + python -m pip install . # this will install a different version of hdmf from the current one cd .. python -m pip uninstall -y hdmf # uninstall the other version of hdmf python -m pip install . # reinstall current branch of hdmf diff --git a/.github/workflows/run_tests.yml b/.github/workflows/run_tests.yml index d800d86f1..2723e03d0 100644 --- a/.github/workflows/run_tests.yml +++ b/.github/workflows/run_tests.yml @@ -243,7 +243,7 @@ jobs: - name: Install run dependencies run: | - pip install -e . + pip install . pip list - name: Conda reporting diff --git a/CHANGELOG.md b/CHANGELOG.md index 00eeeb5dd..5d5a2cc62 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,7 @@ - Updated `_field_config` to take `type_map` as an argument for APIs. @mavaylon1 [#1094](https://github.com/hdmf-dev/hdmf/pull/1094) - Added `TypeConfigurator` to automatically wrap fields with `TermSetWrapper` according to a configuration file. @mavaylon1 [#1016](https://github.com/hdmf-dev/hdmf/pull/1016) - Updated `TermSetWrapper` to support validating a single field within a compound array. @mavaylon1 [#1061](https://github.com/hdmf-dev/hdmf/pull/1061) +- Updated testing to not install in editable mode and not run `coverage` by default. @rly [#1107](https://github.com/hdmf-dev/hdmf/pull/1107) ## HDMF 3.13.0 (March 20, 2024) diff --git a/pyproject.toml b/pyproject.toml index b60ae6943..e5584b581 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -77,7 +77,6 @@ packages = ["src/hdmf"] # verbose = 1 [tool.pytest.ini_options] -addopts = "--cov --cov-report html" norecursedirs = "tests/unit/helpers" [tool.codespell] @@ -86,17 +85,17 @@ ignore-words-list = "datas" [tool.coverage.run] branch = true -source = ["src/"] -omit = [ - "src/hdmf/_due.py", - "src/hdmf/testing/*", -] +source = ["hdmf"] [tool.coverage.report] exclude_lines = [ "pragma: no cover", "@abstract" ] +omit = [ + "*/hdmf/_due.py", + "*/hdmf/testing/*", +] # [tool.black] # line-length = 120 diff --git a/tox.ini b/tox.ini index aeb743c45..75b011aa0 100644 --- a/tox.ini +++ b/tox.ini @@ -8,7 +8,6 @@ requires = pip >= 22.0 [testenv] download = True -usedevelop = True setenv = PYTHONDONTWRITEBYTECODE = 1 VIRTUALENV_PIP = 23.3.1