Skip to content

Commit be6901c

Browse files
fix run order-dependant test failure
1 parent 599cfea commit be6901c

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

bpython/test/test_curtsies_repl.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
import sys
77
import tempfile
88
import io
9+
import importlib
910
from functools import partial
1011
from contextlib import contextmanager
1112
from six.moves import StringIO
@@ -291,6 +292,8 @@ def setUp(self):
291292
self.open = partial(io.open, mode='wt', encoding='utf-8')
292293
self.dont_write_bytecode = sys.dont_write_bytecode
293294
sys.dont_write_bytecode = True
295+
if py3:
296+
importlib.invalidate_caches()
294297

295298
def tearDown(self):
296299
sys.dont_write_bytecode = self.dont_write_bytecode

0 commit comments

Comments
 (0)