Restored re pickling test.
Issue #22166: clear codec caches in test_codecs