1
0
mirror of https://github.com/bpatrik/pigallery2.git synced 2024-12-25 02:04:15 +02:00

adding service test placeholders

This commit is contained in:
Braun Patrik 2016-05-10 23:19:46 +02:00
parent f53c537a9d
commit 06e45f2a95
3 changed files with 90 additions and 0 deletions

View File

@ -0,0 +1,30 @@
import {it, inject, beforeEachProviders} from "@angular/core/testing";
import {BaseRequestOptions, Http} from "@angular/http";
import {MockBackend} from "@angular/http/testing";
import {provide} from "@angular/core";
import "rxjs/Rx";
import {NetworkService} from "../model/network/network.service";
import {AdminService} from "./admin.service";
describe('AdminService', () => {
beforeEachProviders(() => [
MockBackend,
BaseRequestOptions,
provide(Http, {
useFactory: (backend, options) => {
return new Http(backend, options);
}, deps: [MockBackend, BaseRequestOptions]
}),
NetworkService,
AdminService
]);
it('placeholder test', inject([], () => {
expect(true).toBe(true);
}));
});

View File

@ -0,0 +1,30 @@
import {it, inject, beforeEachProviders} from "@angular/core/testing";
import {BaseRequestOptions, Http} from "@angular/http";
import {MockBackend} from "@angular/http/testing";
import {provide} from "@angular/core";
import "rxjs/Rx";
import {NetworkService} from "../model/network/network.service";
import {GalleryService} from "./gallery.service";
describe('GalleryService', () => {
beforeEachProviders(() => [
MockBackend,
BaseRequestOptions,
provide(Http, {
useFactory: (backend, options) => {
return new Http(backend, options);
}, deps: [MockBackend, BaseRequestOptions]
}),
NetworkService,
GalleryService
]);
it('placeholder test', inject([], () => {
expect(true).toBe(true);
}));
});

View File

@ -0,0 +1,30 @@
import {it, inject, beforeEachProviders} from "@angular/core/testing";
import {BaseRequestOptions, Http} from "@angular/http";
import {MockBackend} from "@angular/http/testing";
import {provide} from "@angular/core";
import "rxjs/Rx";
import {AutoCompleteService} from "./autocomplete.service";
import {NetworkService} from "../../model/network/network.service";
describe('AutoCompleteService', () => {
beforeEachProviders(() => [
MockBackend,
BaseRequestOptions,
provide(Http, {
useFactory: (backend, options) => {
return new Http(backend, options);
}, deps: [MockBackend, BaseRequestOptions]
}),
NetworkService,
AutoCompleteService
]);
it('placeholder test', inject([], () => {
expect(true).toBe(true);
}));
});