Change unit tests to support promise-based controllers