diff --git a/src/tad_dftd4/charges.py b/src/tad_dftd4/charges.py index 7f8e2e5..3025c72 100644 --- a/src/tad_dftd4/charges.py +++ b/src/tad_dftd4/charges.py @@ -93,8 +93,6 @@ def __init__( self.eta = eta self.rad = rad - print(self.device) - print(self.chi.device) if any( tensor.device != self.device for tensor in (self.chi, self.kcn, self.eta, self.rad) diff --git a/test/conftest.py b/test/conftest.py index a0f0fa6..2d33490 100644 --- a/test/conftest.py +++ b/test/conftest.py @@ -18,6 +18,7 @@ """ Setup for pytest. """ +from __future__ import annotations import pytest import torch diff --git a/tox.ini b/tox.ini index 520c638..8b2c80d 100644 --- a/tox.ini +++ b/tox.ini @@ -20,38 +20,13 @@ envlist = py{38,39,310,311} [testenv] deps = .[tox] +commands = + pytest -vv -n logical {posargs:--random-order-bucket=global test} + +# do not run in parallel to collect coverage data +[testenv:py311] commands = coverage erase - coverage run -m pytest -n logical -vv {posargs:-m "not large" test} + coverage run -m pytest -vv {posargs:-m "not large" --random-order-bucket=global test} coverage report -m coverage xml -o coverage.xml - - -# [tox] -# envlist = py310-torch{1110,1121,1130} - - -# [testenv] -# deps = -# covdefaults -# coverage -# pytest -# commands = -# coverage erase -# coverage run -m pytest -svv {posargs:test} -# coverage report -m -# coverage xml -o coverage.xm - -# [testenv:py310-torch1110] -# deps = -# {[testenv]deps} -# commands = -# pip install torch==1.11.0+cpu -f https://download.pytorch.org/whl/torch_stable.html -# {[testenv]commands} - -# [testenv:py310-torch1121] -# deps = -# {[testenv]deps} -# commands = -# pip install torch==1.12.1+cpu -f https://download.pytorch.org/whl/torch_stable.html -# {[testenv]commands}