[Addressability} Unit Test

Completed unit tests to accomodate
for url path check prior to setting
the current . WTD 23.
This commit is contained in:
Shivam Dave
2015-06-26 12:51:25 -07:00
parent 3de4473159
commit 2e716bdbe3
2 changed files with 13 additions and 4 deletions

View File

@ -68,6 +68,10 @@ define(
fireWatch("representation.selected.key", "xyz");
expect(mockLocation.search).toHaveBeenCalledWith('view', "xyz");
// Allows the path index to be checked
// prior to setting $route.current
mockLocation.path.andReturn("/browse/");
// Exercise the Angular workaround
mockScope.$on.mostRecentCall.args[1]();
expect(mockUnlisten).toHaveBeenCalled();