Raise coveraged and style

Fix Code Style.
Only do mysql backups when we have a mysql backend.
Refactor all the tests! Raise resource coverage to 100%!