freedomofpress/securedrop — pull request #406 by jacksingleton (2014-05-26 21:43:07+00:00)
Title: Fixed hanging functional tests when starting vagrant

When setup_dev.sh was ran by vagrant, it used "sudo -u vagrant" to run as the correct user.

sudo was not setting the home directory, so when firefox started it tried to create a profile in "/root/.mozilla" while running as the "vagrant" user. It didn't have permission to do so and hung, not responding to webdriver.

Adding the -H option forces sudo to set the correct home directory, and fixes the problem.

Follow up tasks:
- always keep firefox logs to aid debugging
- have functional tests fail gracefully when firefox stops responding

closes #368