Change hostname_equals_servername to get_hostname
This patch fixes the issue with current logic of checking hostname
equals servername. The function hostname_equals_servername is a
util function, which means assert calls cannot be made there.
It only returns True or False based on comparison of hostname and
vm name.
However, if they are not equal, one can never know what was the
expected value vs the actual value of hostname because the assertTrue
call inside the test doesn't reveal that info.
Util functions should better just return hostname value and comparison
is to be made in actual test using assertEqual, this will help debugging
and logging the values of actual vm name and hostname returned from
util function.
Change-Id: I8c89680471547c4aeb556a34eb3b298f9ffbed62
3 files changed