From b694d7a3e1b04bb942e5ba8224762d706f98a371 Mon Sep 17 00:00:00 2001 From: crupest Date: Thu, 21 Feb 2019 23:36:41 +0800 Subject: Add unit test. --- Timeline/ClientApp/src/app/home/home.component.spec.ts | 5 +++-- Timeline/ClientApp/src/app/home/home.component.ts | 13 ------------- 2 files changed, 3 insertions(+), 15 deletions(-) (limited to 'Timeline/ClientApp/src/app/home') diff --git a/Timeline/ClientApp/src/app/home/home.component.spec.ts b/Timeline/ClientApp/src/app/home/home.component.spec.ts index 490e81bd..74bedd08 100644 --- a/Timeline/ClientApp/src/app/home/home.component.spec.ts +++ b/Timeline/ClientApp/src/app/home/home.component.spec.ts @@ -2,15 +2,16 @@ import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { HomeComponent } from './home.component'; + describe('HomeComponent', () => { let component: HomeComponent; let fixture: ComponentFixture; beforeEach(async(() => { TestBed.configureTestingModule({ - declarations: [ HomeComponent ] + declarations: [HomeComponent], }) - .compileComponents(); + .compileComponents(); })); beforeEach(() => { diff --git a/Timeline/ClientApp/src/app/home/home.component.ts b/Timeline/ClientApp/src/app/home/home.component.ts index 873aee7f..2b16eef7 100644 --- a/Timeline/ClientApp/src/app/home/home.component.ts +++ b/Timeline/ClientApp/src/app/home/home.component.ts @@ -1,10 +1,4 @@ import { Component, OnInit } from '@angular/core'; -import { HttpClient } from '@angular/common/http'; - -class LoginInfo { - username = ''; - password = ''; -} @Component({ selector: 'app-home', @@ -13,15 +7,8 @@ class LoginInfo { }) export class HomeComponent implements OnInit { - loginInfo = new LoginInfo(); message = ''; - constructor(/* private http: HttpClient */) { } - ngOnInit() { } - - tryLogin() { - alert('Not implemented!!!'); - } } -- cgit v1.2.3