Add adjointness and inverse test
I propose to add a adjointness test and a test for the inverse to the LinearOperator
base class. This might encourage users to use these tests more often.
TODO: If you like this feature, we should use this functionality in the tests and also in the demos.
Merge request reports
Activity
I'm in favor of separating code which implements features from code which tests these features. Introducing a file called "test_helpers.py" would be fine, I think, but it should go into nifty4/extras/, for example, and should not be made available via
nifty4/__init__.py
.I would not execute self-tests in the demos. These are meant to demonstrate features. If people want to see how tests can be written, the test/ directory is the right place to look.
Edited by Martin ReineckeAnything is fine with me as long as I can import it easily ;)
I tried to move it to a
extra
directory. @mtr, can you check whether I did all imports correctly?added 2 commits
Wouldn't
nosetests -w test
do the trick? Then it ignores everything undernifty4
that may look like a test...Edited by Martin Reinecke