mirror of
https://github.com/xuthus83/pigallery2.git
synced 2024-11-03 21:04:03 +08:00
fixing user.service test
This commit is contained in:
parent
3b0bcc44b0
commit
1ec6ed6985
@ -39,9 +39,9 @@ describe('UserService', () => {
|
||||
}));
|
||||
|
||||
it('should call getJson at getSessionUser', inject([UserService,NetworkService], (userService,networkService) => {
|
||||
spyOn(networkService,"getJson");
|
||||
let credential = new LoginCredential("name","pass");
|
||||
userService.login(credential);
|
||||
spyOn(networkService,"getJson");
|
||||
userService.getSessionUser();
|
||||
expect(networkService.getJson.calls.argsFor(0)).toEqual(["/user/login"]);
|
||||
}));
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user