Added tests for creating and deleting item in idbag

Each modification of idbag should take one query per item.