From fa3e08dece083282476a395eb7c085a872add62d Mon Sep 17 00:00:00 2001 From: Ronny Pfannschmidt Date: Wed, 17 Nov 2021 14:45:18 +0100 Subject: [PATCH] WIP: #9298-debug --- testing/test_assertrewrite.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/testing/test_assertrewrite.py b/testing/test_assertrewrite.py index 9a01fa9ed..28192e466 100644 --- a/testing/test_assertrewrite.py +++ b/testing/test_assertrewrite.py @@ -4,6 +4,7 @@ import glob import importlib import marshal import os +import pprint import py_compile import stat import sys @@ -1734,7 +1735,7 @@ class TestPyCacheDir: ) -> None: """Integration test for sys.pycache_prefix (#4730).""" pycache_prefix = tmp_path / "my/pycs" - monkeypatch.setattr(sys, "pycache_prefix", str(pycache_prefix)) + monkeypatch.setattr(sys, "pycache_prefix", os.fspath(pycache_prefix)) monkeypatch.setattr(sys, "dont_write_bytecode", False) pytester.makepyfile( @@ -1748,6 +1749,8 @@ class TestPyCacheDir: } ) result = pytester.runpytest() + pprint.pprint(list(tmp_path.glob("**"))) + assert result.ret == 0 test_foo = pytester.path.joinpath("src/test_foo.py")