[
https://issues.apache.org/jira/browse/OFBIZ-2259?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12693980#action_12693980
]
David E. Jones commented on OFBIZ-2259:
---------------------------------------
Thinking about this more I like the idea of a sort of cloned delegator. In
other words instead of doing something like:
modelSuite.getDelegator().setTestMode(true);
we would do something like:
GenericDelegator testDelegator = modelSuite.getDelegator().makeTestDelegator();
and the later on near the end instead of:
modelSuite.getDelegator().performUndo();
modelSuite.getDelegator().setTestMode(false);
maybe something like:
testDelegator.rollback();
> Testing - Rollback database changes after each test-suite using the
> GenericDelegator
> ------------------------------------------------------------------------------------
>
> Key: OFBIZ-2259
> URL: https://issues.apache.org/jira/browse/OFBIZ-2259
> Project: OFBiz
> Issue Type: New Feature
> Components: framework
> Reporter: Scott Gray
> Assignee: Scott Gray
> Attachments: rollback.patch
>
>
> During testing have the delegator keep track of all changes made to the
> database and then roll them back at the end of each test suite. This will
> allow the same demo data to be reused across test suites without having to
> worry about what changes previous tests have made to the data and solves this
> problem regardless of the database being used.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.