Failed stored procedures return errors correctly

This test makes sure that if there is an error in a stored procedure
inside a transaction, that the error is propogated back up the stack
and into db/mysql.js. Trying to make an existing SP fail and putting
the correct one back into place seemed a bit fragile, so this adds
a new one (which we know will fail) and then monkey patches `db` so
that it mirrors the other methods by just calling `db.write()`. This
is about as close as we can get without it becoming spaghetti.