Hi Jeroen, On 2017-10-30, Jeroen Demeyer <jdeme...@cage.ugent.be> wrote: > On 2017-10-30 08:41, Simon King wrote: >> would you rather have no test at all than a >> superficial consistency test on a wide range of objects, versions and >> machines? > > Yes. A test which doesn't actually test anything is worse than no test. > That's exactly the situation that we currently have with the pickle jar.
The current pickle jar tests that the pickles unpickle. My proposition is: Test that pickles of the same object created under different circumstances (1) unpickle, (2) evaluate equal and (3) pass TestSuite.run(). That'd be a progress, compared with the current pickle jar, and would indeed a nontrivial test, since it should be easy to create a custom pickle format that simply dumps a bit pattern and would behave differently on a big endian or little endian machine. Or (which is the case for MeatAxe matrices) you can store data in a memory chunk of size m*sizeof(long), even when the actual data doesn't fill all bytes of the last long in the memory chunk; whether or not it is used for specific data may depend on sizeof(long). In order to make pickling machine independent (which it *should* be, IMHO), you need to dump only the bytes that are actually used. Regards, Simon -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at https://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.