diff --git a/testsuite/MDAnalysisTests/coordinates/test_xdr.py b/testsuite/MDAnalysisTests/coordinates/test_xdr.py index 5de0447eb9..6f768cd6e1 100644 --- a/testsuite/MDAnalysisTests/coordinates/test_xdr.py +++ b/testsuite/MDAnalysisTests/coordinates/test_xdr.py @@ -892,9 +892,7 @@ def test_unsupported_format(self, traj): @pytest.mark.skipif(get_userid() == 0, reason="cannot readonly as root") def test_persistent_offsets_readonly(self, tmpdir): - test_file = Path(self.filename) - tmp_path = str(tmpdir) - shutil.copy(test_file, tmp_path) + shutil.copy(self.filename, str(tmpdir)) if os.name == 'nt': # Windows platform has a unique way to deny write access