Hanno Schlichting wrote:
Maurits van Rees wrote:
Derek Richardson, on 2007-08-22:
Just in case, let's commit to the ZODB.
>>> from transaction import get
>>> get().commit()
This has been deprecated and might not work anymore in 3.0. Use:
>>> import transaction
>>> transaction.commit()
While I don't really know why the original test is not working, one
remark about transactions.
Please don't do a full commit in tests unless you really need one and
know what you are doing. A savepoint:
>>> transaction.savepoint(optimistic=True)
will write your changes to the ZODB as well, but even this should
usually not be needed as your changes will be visible in the same
transaction anyways.
I changed the test to use savepoint. savepoint successfully completes, but the
test still fails.
Thanks for the pointer on proper test cases, though.
Derek
_______________________________________________
Product-Developers mailing list
[email protected]
http://lists.plone.org/mailman/listinfo/product-developers