The tests for cinder/image/image_utils.py mainly use mox. This patch
replaces the tests in cinder/tests/test_image_utils.py and adds
additional tests that use mock.
This commit removes the following trivial functions that were only used
once within image_utils and don't appear to provide any tangible
benefit:
- file_exist
- rename_file