Fix a wrong logical judgment in get_target_id()

  * Wrong using 'elif' instead of 'if', then it will never judge if this target using
    the emulated image name.
  * Delete the duplicated judgment when cleanup.

Signed-off-by: Yanbing Du <ydu@redhat.com>
libirt: Add test for virsh find-storage-pool-sources-as

Signed-off-by: Yanbing Du <ydu@redhat.com>
Merge pull request #1122 from will-Do/find_pool_source_as

Add test for virsh find-storage-pool-sources-as and bug fix