Stop leaking in images tests

Resources created would not be cleanup if exception raised
in setUpClass. This patch use decorator 'safe_setup' to
cleanup those resources in images tests.

Partially Implements: blueprint stop-leaking

Change-Id: Ifbb534c008af0f6aca2a75d5c98d6e451a71eacd
2 files changed