Skip to content
Closed
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions testsuite/MDAnalysisTests/coordinates/test_dms.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,3 +93,13 @@ def test_frame_index_0(self, universe):
def test_frame_index_1_raises_IndexError(self, universe):
with pytest.raises(IndexError):
universe.trajectory[1]

def test_convert_pos_from_native(self):
u_native = mda.Universe(DMS, convert_units=False)
u_conv = mda.Universe(DMS, convert_units=True)

np.testing.assert_allclose(
u_conv.atoms.positions,
u_native.atoms.positions,
rtol=1e-6,
Copy link
Copy Markdown
Member

@RMeli RMeli Jan 15, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does the default rtol fails here?

Maybe also worth adding a comment that we expect this to be the same since DMS and MDAnalysis use the same units?

)
Loading