From e619f452877c54c2801415abaf0f93ff3889adb4 Mon Sep 17 00:00:00 2001 From: Matthew Honnibal Date: Thu, 6 Dec 2018 20:43:47 +0100 Subject: [PATCH] Fix pickle tests --- spacy/tests/test_pickles.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/spacy/tests/test_pickles.py b/spacy/tests/test_pickles.py index 0ae829753..ad2c33e95 100644 --- a/spacy/tests/test_pickles.py +++ b/spacy/tests/test_pickles.py @@ -2,8 +2,8 @@ from __future__ import unicode_literals import pytest -import dill as pickle import numpy +import srsly from spacy.strings import StringStore from spacy.vocab import Vocab from spacy.attrs import NORM @@ -14,8 +14,8 @@ def test_pickle_string_store(text1, text2): stringstore = StringStore() store1 = stringstore[text1] store2 = stringstore[text2] - data = pickle.dumps(stringstore, protocol=-1) - unpickled = pickle.loads(data) + data = srsly.pickle_dumps(stringstore, protocol=-1) + unpickled = srsly.pickle_loads(data) assert unpickled[text1] == store1 assert unpickled[text2] == store2 assert len(stringstore) == len(unpickled)