Skip to content

Commit

Permalink
Merge pull request #13799 from jerobado/replace-tmpdir-in-modeling-tests
Browse files Browse the repository at this point in the history
  • Loading branch information
WilliamJamieson committed Oct 6, 2022
2 parents 2c6cb47 + 4fcfd6d commit 75f9b60
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions astropy/modeling/tests/test_core.py
Expand Up @@ -544,7 +544,7 @@ def test_units_with_bounding_box():
""".strip()


def test_rename_path(tmpdir):
def test_rename_path(tmp_path):

# Regression test for a bug that caused the path to the class to be
# incorrect in a renamed model's __repr__.
Expand All @@ -558,7 +558,7 @@ def test_rename_path(tmpdir):
paths = [os.path.dirname(astropy.__path__[0])] + sys.path
env['PYTHONPATH'] = os.pathsep.join(paths)

script = tmpdir.join('rename.py').strpath
script = tmp_path / 'rename.py'
with open(script, 'w') as f:
f.write(MODEL_RENAME_CODE)

Expand Down

0 comments on commit 75f9b60

Please sign in to comment.