Write test for and fix bug with going to homepage