# HG changeset patch # User Boris Feld # Date 1501515825 -7200 # Node ID 6c142f2796255a0530fe0a74eb31c4e0b1f81661 # Parent 806351695c6a27a1a35600c637299aad3d9b6b52 pypy: fix failing test files with Pypy5.6.0 Pypy 5.6.0 saves cached bytecode files in __pycache__ directory, clean them in tests to fix loading old test extensions code. Doing so should also helps for Python3.x migration. diff -r 806351695c6a -r 6c142f279625 tests/test-commandserver.t --- a/tests/test-commandserver.t Sun Jul 30 12:19:46 2017 +0530 +++ b/tests/test-commandserver.t Mon Jul 31 17:43:45 2017 +0200 @@ -234,7 +234,9 @@ *** runcommand --config hooks.pre-identify=python:hook.hook id eff892de26ec tip +Clean hook cached version $ rm hook.py* + $ rm -Rf __pycache__ $ echo a >> a >>> import os diff -r 806351695c6a -r 6c142f279625 tests/test-fncache.t --- a/tests/test-fncache.t Sun Jul 30 12:19:46 2017 +0530 +++ b/tests/test-fncache.t Mon Jul 31 17:43:45 2017 +0200 @@ -270,7 +270,11 @@ > cmdtable = {} > > EOF + +Clean cached version $ rm -f "${extpath}c" + $ rm -Rf "`dirname $extpath`/__pycache__" + $ touch z $ hg ci -qAm z transaction abort! @@ -305,7 +309,11 @@ > cmdtable = {} > > EOF + +Clean cached versions $ rm -f "${extpath}c" + $ rm -Rf "`dirname $extpath`/__pycache__" + $ hg up -q 1 $ touch z $ hg ci -qAm z 2>/dev/null