Add unit tests on tags manipulations in DB API layer

Change-Id: I91280fa45f5aeff0e682f9ae3bce593f8b66f961
Merge "Add unit tests on tags manipulations in DB API layer"