Skip to content

Commit

Permalink
Added test for checking for invalid default unit
Browse files Browse the repository at this point in the history
  • Loading branch information
tanishy7777 committed Dec 13, 2024
1 parent af7b46a commit 52db811
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions testsuite/MDAnalysisTests/analysis/test_density.py
Original file line number Diff line number Diff line change
Expand Up @@ -384,6 +384,12 @@ def test_warn_results_deprecated(self, universe):
with pytest.warns(DeprecationWarning, match=wmsg):
assert_equal(D.density.grid, D.results.density.grid)

def test_density_analysis_invalid_unit(self):
u = mda.Universe(TPR, XTC)
ow = u.select_atoms("name OW")
D = mda.analysis.density.DensityAnalysis(ow, delta=1.0)
D.run()
D.results.density.convert_density()

class TestGridImport(object):

Expand Down

0 comments on commit 52db811

Please sign in to comment.