Export more types, add stub for common-map library
All checks were successful
FarmMaps.Develop/FarmMapsLib/develop This commit looks good
All checks were successful
FarmMaps.Develop/FarmMapsLib/develop This commit looks good
This commit is contained in:
25
projects/common-map/src/lib/common-map.component.spec.ts
Normal file
25
projects/common-map/src/lib/common-map.component.spec.ts
Normal file
@@ -0,0 +1,25 @@
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
|
||||
import { CommonMapComponent } from './common-map.component';
|
||||
|
||||
describe('CommonMapComponent', () => {
|
||||
let component: CommonMapComponent;
|
||||
let fixture: ComponentFixture<CommonMapComponent>;
|
||||
|
||||
beforeEach(async(() => {
|
||||
TestBed.configureTestingModule({
|
||||
declarations: [ CommonMapComponent ]
|
||||
})
|
||||
.compileComponents();
|
||||
}));
|
||||
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(CommonMapComponent);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should create', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
19
projects/common-map/src/lib/common-map.component.ts
Normal file
19
projects/common-map/src/lib/common-map.component.ts
Normal file
@@ -0,0 +1,19 @@
|
||||
import { Component, OnInit } from '@angular/core';
|
||||
|
||||
@Component({
|
||||
selector: 'lib-common-map',
|
||||
template: `
|
||||
<p>
|
||||
common-map works!
|
||||
</p>
|
||||
`,
|
||||
styles: []
|
||||
})
|
||||
export class CommonMapComponent implements OnInit {
|
||||
|
||||
constructor() { }
|
||||
|
||||
ngOnInit() {
|
||||
}
|
||||
|
||||
}
|
10
projects/common-map/src/lib/common-map.module.ts
Normal file
10
projects/common-map/src/lib/common-map.module.ts
Normal file
@@ -0,0 +1,10 @@
|
||||
import { NgModule } from '@angular/core';
|
||||
import { CommonMapComponent } from './common-map.component';
|
||||
|
||||
@NgModule({
|
||||
declarations: [CommonMapComponent],
|
||||
imports: [
|
||||
],
|
||||
exports: [CommonMapComponent]
|
||||
})
|
||||
export class CommonMapModule { }
|
12
projects/common-map/src/lib/common-map.service.spec.ts
Normal file
12
projects/common-map/src/lib/common-map.service.spec.ts
Normal file
@@ -0,0 +1,12 @@
|
||||
import { TestBed } from '@angular/core/testing';
|
||||
|
||||
import { CommonMapService } from './common-map.service';
|
||||
|
||||
describe('CommonMapService', () => {
|
||||
beforeEach(() => TestBed.configureTestingModule({}));
|
||||
|
||||
it('should be created', () => {
|
||||
const service: CommonMapService = TestBed.get(CommonMapService);
|
||||
expect(service).toBeTruthy();
|
||||
});
|
||||
});
|
9
projects/common-map/src/lib/common-map.service.ts
Normal file
9
projects/common-map/src/lib/common-map.service.ts
Normal file
@@ -0,0 +1,9 @@
|
||||
import { Injectable } from '@angular/core';
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
})
|
||||
export class CommonMapService {
|
||||
|
||||
constructor() { }
|
||||
}
|
7
projects/common-map/src/public-api.ts
Normal file
7
projects/common-map/src/public-api.ts
Normal file
@@ -0,0 +1,7 @@
|
||||
/*
|
||||
* Public API Surface of common-map
|
||||
*/
|
||||
|
||||
export * from './lib/common-map.service';
|
||||
export * from './lib/common-map.component';
|
||||
export * from './lib/common-map.module';
|
22
projects/common-map/src/test.ts
Normal file
22
projects/common-map/src/test.ts
Normal file
@@ -0,0 +1,22 @@
|
||||
// This file is required by karma.conf.js and loads recursively all the .spec and framework files
|
||||
|
||||
import 'core-js/es7/reflect';
|
||||
import 'zone.js/dist/zone';
|
||||
import 'zone.js/dist/zone-testing';
|
||||
import { getTestBed } from '@angular/core/testing';
|
||||
import {
|
||||
BrowserDynamicTestingModule,
|
||||
platformBrowserDynamicTesting
|
||||
} from '@angular/platform-browser-dynamic/testing';
|
||||
|
||||
declare const require: any;
|
||||
|
||||
// First, initialize the Angular testing environment.
|
||||
getTestBed().initTestEnvironment(
|
||||
BrowserDynamicTestingModule,
|
||||
platformBrowserDynamicTesting()
|
||||
);
|
||||
// Then we find all the tests.
|
||||
const context = require.context('./', true, /\.spec\.ts$/);
|
||||
// And load the modules.
|
||||
context.keys().map(context);
|
Reference in New Issue
Block a user