Added tests to check HOSTNAME variable behavior for #4