Add skeleton test for ng WorkPackagesController

Use `$timeout` service with `$timeout.flush()` as a shortcut to build
and resolve promises.

Signed-off-by: Alex Coles <alex@alexbcoles.com>
Fix ng WorkPackagesController relative root path handling

Extract projectIdentifier correctly from window.location when the
Rails application is running with a relative root path configured
(this solution is currently sub-optimal, relying on a global variable)

User Story #7089

Signed-off-by: Alex Coles <alex@alexbcoles.com>
Merge pull request #1232 from opf/fix/angular-rails-relative-path

Fix/angular rails relative path