Fix rollback from new state (unload record)

Add more rollback tests
Merge pull request #1166 from tchak/rollback-tests

Fix rollback from new state (unload record)