mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-07 01:54:15 +00:00
Updated test.
This commit is contained in:
@@ -25,13 +25,10 @@ function getItem(metadata: MetadataMap) {
|
||||
const noMetadata = new MetadataMap();
|
||||
|
||||
const mockHostWindowService = {
|
||||
// This isn't really testing mobile status, the return observable just allows the test to run.
|
||||
widthCategory: observableOf(true),
|
||||
};
|
||||
|
||||
const mockHostWindowServiceMobile = {
|
||||
widthCategory: observableOf(false),
|
||||
};
|
||||
|
||||
describe('MiradorViewerComponent with search', () => {
|
||||
let comp: MiradorViewerComponent;
|
||||
let fixture: ComponentFixture<MiradorViewerComponent>;
|
||||
@@ -152,7 +149,7 @@ describe('MiradorViewerComponent with multiple images', () => {
|
||||
});
|
||||
|
||||
|
||||
describe('MiradorViewerComponent with a single image in mobile configuration', () => {
|
||||
describe('MiradorViewerComponent with a single image', () => {
|
||||
let comp: MiradorViewerComponent;
|
||||
let fixture: ComponentFixture<MiradorViewerComponent>;
|
||||
const viewerService = jasmine.createSpyObj('MiradorViewerService', ['showEmbeddedViewer', 'getImageCount']);
|
||||
@@ -170,7 +167,7 @@ describe('MiradorViewerComponent with a single image in mobile configuration', (
|
||||
declarations: [MiradorViewerComponent],
|
||||
providers: [
|
||||
{ provide: BitstreamDataService, useValue: {} },
|
||||
{ provide: HostWindowService, useValue: mockHostWindowServiceMobile }
|
||||
{ provide: HostWindowService, useValue: mockHostWindowService }
|
||||
],
|
||||
schemas: [NO_ERRORS_SCHEMA]
|
||||
}).overrideComponent(MiradorViewerComponent, {
|
||||
@@ -200,10 +197,6 @@ describe('MiradorViewerComponent with a single image in mobile configuration', (
|
||||
expect(viewerService.getImageCount).toHaveBeenCalled();
|
||||
});
|
||||
|
||||
it('should be in mobile configuration', () => {
|
||||
expect(comp.notMobile).toBeFalse();
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
});
|
||||
|
Reference in New Issue
Block a user