Add tests for metadata updates

This change adds couple of unit tests to persistence base test case,
to verify that metadata updates are not lost.

Change-Id: I467b21eb59e9b85a689086d09c775b714a70d02a
Merge "Add tests for metadata updates"