diff options
author | Arundathi Patil <arundpil@in.ibm.com> | 2018-08-02 14:43:20 +0530 |
---|---|---|
committer | Arundathi Patil <arundpil@in.ibm.com> | 2018-08-02 13:15:41 +0000 |
commit | 007abaaf261386af4263c75dbd23b42699003dcf (patch) | |
tree | 700a1a4f2fbd9b213705f791b88626895cc96e15 | |
parent | b2a71e7b2b929f25379dc2fb51d2c3abdbf0f346 (diff) |
userloginForm- Fixed test case
Test case in userlogin form was expecting wrong values because of which
the test case failed. Changed the test case expecting values to proper
values.
Issue-ID: APPC-1064
Change-Id: I9b1aedc70a806b235c0b56d936370e8a1a62d2dd
Signed-off-by: Arundathi Patil <arundpil@in.ibm.com>
-rw-r--r-- | src/app/vnfs/userlogin-form/userlogin-form.component.spec.ts | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/app/vnfs/userlogin-form/userlogin-form.component.spec.ts b/src/app/vnfs/userlogin-form/userlogin-form.component.spec.ts index 16863a4..ea97439 100644 --- a/src/app/vnfs/userlogin-form/userlogin-form.component.spec.ts +++ b/src/app/vnfs/userlogin-form/userlogin-form.component.spec.ts @@ -95,11 +95,12 @@ describe('userloginFormComponent', () => { component.getData(); const url = spy.calls.first().args[0]; - - expect(url.length).toBe(2); - expect(url[0]).toEqual('vnfs'); - - expect(url[1]).toEqual('list'); + // return url is set to '/home' in mockActiveRoute. + expect(url.length).toBe(5); + expect(url[0]).toEqual('/'); + expect(url[1]).toEqual('h'); + expect(localStorage['userId']).toBe('test Usr'); })); }); + |