make unit tests run in both browser + console via Phantom