merge YARN-406 from trunk. Fix TestRackResolver to function in networks where "host1" resolves to a valid host. Contributed by Hitesh Shah.