mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[ADF-3501] PDF view fixes (#3735)
* PDF view fixes * updated package.lock * fix failing tests * restore test * use fake web worker for tests * test fixes * test fixes * disable i18n test * test fixes
This commit is contained in:
committed by
Eugenio Romano
parent
567d172176
commit
c0acc53eb9
@@ -16,14 +16,11 @@
|
||||
*/
|
||||
|
||||
import { SimpleChange } from '@angular/core';
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import { MediaPlayerComponent } from './mediaPlayer.component';
|
||||
import { setupTestBed } from '../../testing/setupTestBed';
|
||||
import { CoreModule } from '../../core.module';
|
||||
|
||||
import {
|
||||
ContentService
|
||||
} from '../../services';
|
||||
import { ContentService } from '../../services/content.service';
|
||||
|
||||
describe('Test Media player component ', () => {
|
||||
|
||||
@@ -40,9 +37,9 @@ describe('Test Media player component ', () => {
|
||||
imports: [CoreModule.forRoot()]
|
||||
});
|
||||
|
||||
beforeEach(async(() => {
|
||||
beforeEach(() => {
|
||||
service = TestBed.get(ContentService);
|
||||
}));
|
||||
});
|
||||
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(MediaPlayerComponent);
|
||||
@@ -51,10 +48,13 @@ describe('Test Media player component ', () => {
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
afterEach(() => {
|
||||
fixture.destroy();
|
||||
});
|
||||
|
||||
it('should thrown an error If no url or no blob are passed', () => {
|
||||
let change = new SimpleChange(null, null, true);
|
||||
expect(() => {
|
||||
component.ngOnChanges({ 'blobFile': change });
|
||||
component.ngOnChanges({});
|
||||
}).toThrow(new Error('Attribute urlFile or blobFile is required'));
|
||||
});
|
||||
|
||||
|
Reference in New Issue
Block a user