diff options
author | crupest <crupest@outlook.com> | 2019-04-13 13:03:18 +0800 |
---|---|---|
committer | crupest <crupest@outlook.com> | 2019-04-13 13:03:18 +0800 |
commit | fac5006e7eaf7f7bc23e92a2b3059d4f1b37fa07 (patch) | |
tree | 39cf181a18a3dc443dbab5669a04d0a23cdefd00 /Timeline/ClientApp/src/app/user/user-logout/user-logout.component.spec.ts | |
parent | 8c5e7069d2651fb6fae641dfe482d7a0910b3fd1 (diff) | |
download | timeline-fac5006e7eaf7f7bc23e92a2b3059d4f1b37fa07.tar.gz timeline-fac5006e7eaf7f7bc23e92a2b3059d4f1b37fa07.tar.bz2 timeline-fac5006e7eaf7f7bc23e92a2b3059d4f1b37fa07.zip |
Init separate.
Diffstat (limited to 'Timeline/ClientApp/src/app/user/user-logout/user-logout.component.spec.ts')
-rw-r--r-- | Timeline/ClientApp/src/app/user/user-logout/user-logout.component.spec.ts | 35 |
1 files changed, 0 insertions, 35 deletions
diff --git a/Timeline/ClientApp/src/app/user/user-logout/user-logout.component.spec.ts b/Timeline/ClientApp/src/app/user/user-logout/user-logout.component.spec.ts deleted file mode 100644 index 855ea4a1..00000000 --- a/Timeline/ClientApp/src/app/user/user-logout/user-logout.component.spec.ts +++ /dev/null @@ -1,35 +0,0 @@ -import { async, ComponentFixture, TestBed } from '@angular/core/testing'; - -import { UserLogoutComponent } from './user-logout.component'; -import { InternalUserService } from '../internal-user-service/internal-user.service'; - -describe('UserLogoutComponent', () => { - let component: UserLogoutComponent; - let fixture: ComponentFixture<UserLogoutComponent>; - - let mockInternalUserService: jasmine.SpyObj<InternalUserService>; - - beforeEach(async(() => { - mockInternalUserService = jasmine.createSpyObj('InternalUserService', ['logout']); - - TestBed.configureTestingModule({ - declarations: [UserLogoutComponent], - providers: [{ provide: InternalUserService, useValue: mockInternalUserService }] - }) - .compileComponents(); - })); - - beforeEach(() => { - fixture = TestBed.createComponent(UserLogoutComponent); - component = fixture.componentInstance; - }); - - it('should create', () => { - expect(component).toBeTruthy(); - }); - - it('should logout on init', () => { - fixture.detectChanges(); - expect(mockInternalUserService.logout).toHaveBeenCalled(); - }); -}); |