It's good that you are checking the logged_in status here.
You might also want to add a test for this.