Skip to content
This repository has been archived by the owner on Nov 22, 2019. It is now read-only.

Commit

Permalink
Fix for build error and test case.
Browse files Browse the repository at this point in the history
  • Loading branch information
tejones committed Mar 12, 2018
1 parent 246e1d0 commit 1cc8e6b
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 9 deletions.
18 changes: 15 additions & 3 deletions ngapp/src/app/core/about-dialog/about-dialog.component.spec.ts
@@ -1,7 +1,12 @@
import { async, ComponentFixture, TestBed } from "@angular/core/testing";

import { HttpModule } from "@angular/http";
import { About } from "@core/about-dialog/about.model";
import { AboutService } from "@core/about-dialog/about.service";
import { MockAboutService } from "@core/about-dialog/mock-about.service";
import { AppSettingsService } from "@core/app-settings.service";
import { LoggerService } from "@core/logger.service";
import { MockAppSettingsService } from "@core/mock-app-settings.service";
import { PatternFlyNgModule } from "patternfly-ng";
import { AboutDialogComponent } from "./about-dialog.component";

describe("AboutDialogComponent", () => {
Expand All @@ -10,9 +15,16 @@ describe("AboutDialogComponent", () => {

beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [ AboutDialogComponent ]
declarations: [ AboutDialogComponent ],
imports: [ HttpModule, PatternFlyNgModule ],
providers: [
AboutService,
{ provide: AppSettingsService, useClass: MockAppSettingsService },
LoggerService ]
})
.compileComponents();
.compileComponents().then(() => {
// nothing to do
});
}));

beforeEach(() => {
Expand Down
10 changes: 4 additions & 6 deletions ngapp/src/app/core/about-dialog/about-dialog.component.ts
Expand Up @@ -16,12 +16,11 @@
*/

import { Component, EventEmitter, Input, OnInit, Output, ViewEncapsulation } from "@angular/core";
import { AboutService } from "@core/about-dialog/about.service";
import { LoggerService } from "@core/logger.service";
import { AboutEvent } from "app/core/about-dialog/about-event";
import { About } from "app/core/about-dialog/about.model";
import { BsModalService } from "ngx-bootstrap/modal";
import { AboutModalConfig } from "patternfly-ng/modal";
import { AboutService } from "@core/about-dialog/about.service";
import { LoggerService } from "@core/logger.service";

@Component({
encapsulation: ViewEncapsulation.None,
Expand All @@ -41,15 +40,14 @@ export class AboutDialogComponent implements OnInit {
*/
@Input() public info: About;

private aboutConfig: AboutModalConfig;
public aboutConfig: AboutModalConfig;
private aboutService: AboutService;
private logger: LoggerService;

/**
* The default contructor
*/
constructor(private modalService: BsModalService,
logger: LoggerService,
constructor(logger: LoggerService,
aboutService: AboutService) {
this.aboutService = aboutService;
this.logger = logger;
Expand Down

0 comments on commit 1cc8e6b

Please sign in to comment.