<commit_before>import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { mock, instance, when } from 'ts-mockito';
import { CesiumService } from '../../services/cesium/cesium.service';
import { providerFromMock } from '../../utils/testingUtils';
import { AcPolylineComponent } from './ac-polyline.component';
import { DynamicPolylineDrawerService } from '../../services/drawers/dynamic-polyline-drawer/dynamic-polyline-drawer.service';

describe('AcPolylineComponent', () => {
	let component: AcPolylineComponent;
	let fixture: ComponentFixture<AcPolylineComponent>;

	const cesiumService = mock(CesiumService);
	const polylineCollection = mock(Cesium.PolylineCollection);

	when(cesiumService.getScene()).thenReturn({primitives: instance(polylineCollection)});

	beforeEach(async(() => {
		TestBed.configureTestingModule({
			declarations: [AcPolylineComponent],
			providers: [DynamicPolylineDrawerService,
				providerFromMock(CesiumService, cesiumService)]
		})
			.compileComponents();
		fixture = TestBed.createComponent(AcPolylineComponent);
		component = fixture.componentInstance;

	}));<commit_msg>fix mocking problem<commit_after>import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { mock, instance, when } from 'ts-mockito';
import { CesiumService } from '../../services/cesium/cesium.service';
import { providerFromMock } from '../../utils/testingUtils';
import { AcPolylineComponent } from './ac-polyline.component';
import { DynamicPolylineDrawerService } from '../../services/drawers/dynamic-polyline-drawer/dynamic-polyline-drawer.service';

describe('AcPolylineComponent', () => {
	let component: AcPolylineComponent;
	let fixture: ComponentFixture<AcPolylineComponent>;

	const cesiumService = mock(CesiumService);
  const polylineCollection = mock(Cesium.PrimitiveCollection);

	when(cesiumService.getScene()).thenReturn({primitives: instance(polylineCollection)});

	beforeEach(async(() => {
		TestBed.configureTestingModule({
			declarations: [AcPolylineComponent],
			providers: [DynamicPolylineDrawerService,
				providerFromMock(CesiumService, cesiumService)]
		})
			.compileComponents();
		fixture = TestBed.createComponent(AcPolylineComponent);
		component = fixture.componentInstance;

	}));
{'fraction_non_alphanumeric': 0.13368513632365875, 'fraction_numerical': 0.0, 'mean_word_length': 6.245222929936306, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '11223', 'n_tokens_mistral': 679, 'n_tokens_neox': 632, 'n_words': 114}