Replace substring in Pickle string differently.

Pickle uses a new format since Python 3, which is incompatible with
Python 2.  This problem now pops up because the replacement string had
a different length, so we broke the pickle protocol with this test.
main
Vincent Driessen 11 years ago
parent d08352b103
commit 85a7a14a4c

@ -57,7 +57,7 @@ class TestWorker(RQTestCase):
job = Job.create(func=div_by_zero, args=(3,))
job.save()
data = self.testconn.hget(job.key, 'data')
invalid_data = data.replace(b'div_by_zero', b'nonexisting_job')
invalid_data = data.replace(b'div_by_zero', b'nonexisting')
assert data != invalid_data
self.testconn.hset(job.key, 'data', invalid_data)

Loading…
Cancel
Save