Skip to content

Commit

Permalink
convert windows paths properly into posix path
Browse files Browse the repository at this point in the history
  • Loading branch information
christian-monch committed Mar 17, 2023
1 parent 20c10f1 commit 1e954de
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions datalad_dataverse/tests/test_dataset.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,10 @@
At least as long as we are using that API layer.
"""

from pathlib import PurePosixPath
from pathlib import (
Path,
PurePosixPath,
)
import json

from datalad_next.tests.utils import md5sum
Expand Down Expand Up @@ -58,7 +61,7 @@ def test_file_handling(


def check_rename_file(odd, fileid, name='place.txt'):
new_path = PurePosixPath('fresh') / name
new_path = PurePosixPath(*(('fresh',) + Path(name).parts))
assert not odd.has_path(new_path)
assert odd.has_fileid(fileid)
odd.rename_file(new_path, fileid)
Expand Down

0 comments on commit 1e954de

Please sign in to comment.