Fix tests to work correctly with conflict resolution.
Add new tests for conflict resolution. The old blanket try-except for conflict resolution was hiding some bugs caused by the pickles used in the test suite. The conflict resolution code imposes some restrictions on the format of pickles. Basically, the conflict resolution requires that the storage API only accept a pickles that constructed according to the ZODB rules. XXX This new restriction sounds unfortunate, but it would require a substantial change to conflict resolution to remove it. The key changes to the test suite are to store only persistent objects and to format the pickles using the standard ZODB format. All tests now use ZODB.tests.MinPO.MinPO instances for data. The pickling is down with zodb_pickle() and zodb_unpickle() defined in StorageTestBase. Add conflict resolution tests to testFileStorage. (They pass.)
Showing
This diff is collapsed.
This diff is collapsed.
Please register or sign in to comment