db lock issues fix test