Skip to content

Commit 2402b31

Browse files
style: pre-commit fixes
1 parent d92e0a5 commit 2402b31

File tree

1 file changed

+11
-6
lines changed

1 file changed

+11
-6
lines changed

tests/test_interpreters.py

+11-6
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,11 @@
11
from __future__ import annotations
22

3-
import pytest
43
import os
54
import pickle
65

6+
import pytest
7+
8+
79
def test_interpreters():
810
"""Makes sure the internals object differs across subinterpreters"""
911

@@ -37,20 +39,23 @@ def test_interpreters():
3739
interp2 = i.create()
3840
try:
3941
pipei, pipeo = os.pipe()
40-
i.run_string(interp1, code, shared={'pipeo':pipeo})
41-
with open(pipei, 'rb') as f:
42+
i.run_string(interp1, code, shared={"pipeo": pipeo})
43+
with open(pipei, "rb") as f:
4244
res1 = pickle.load(f)
4345

4446
pipei, pipeo = os.pipe()
45-
i.run_string(interp2, code, shared={'pipeo':pipeo})
46-
with open(pipei, 'rb') as f:
47+
i.run_string(interp2, code, shared={"pipeo": pipeo})
48+
with open(pipei, "rb") as f:
4749
res2 = pickle.load(f)
4850

4951
# do this while the two interpreters are active
5052
import mod_test_interpreters as m2
53+
5154
print(dir(m))
5255
print(dir(m2))
53-
assert m.internals_at() == m2.internals_at(), "internals should be the same within the main interpreter"
56+
assert m.internals_at() == m2.internals_at(), (
57+
"internals should be the same within the main interpreter"
58+
)
5459
finally:
5560
i.destroy(interp1)
5661
i.destroy(interp2)

0 commit comments

Comments
 (0)