feat: block reference counting

This patch prevents deleting of a block from a vault if the block has
files referring to it. It adds a ConstraintError that is thrown if this
is attempted.

Another patchset will add functional tests for this and hook it into the controllers. 

Implementing this patch broke the file assignement tests because those tests actually deleted blocks assigned to files. That large test was broken into individual tests. 
Good question

I did not validate here since this is a helper (private) function. I made the assumption that anything in a helper function has already been validated.