mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-17 15:03:07 +00:00
Resolve feedback
Inject environment rather than importing it Redo the configuration for better consistency across pages
This commit is contained in:
@@ -15,6 +15,8 @@ import { Collection } from '../core/shared/collection.model';
|
||||
import { PageInfo } from '../core/shared/page-info.model';
|
||||
import { FlatNode } from './flat-node.model';
|
||||
import { FindListOptions } from '../core/data/find-list-options.model';
|
||||
import { APP_CONFIG } from 'src/config/app-config.interface';
|
||||
import { environment } from 'src/environments/environment.test';
|
||||
|
||||
describe('CommunityListService', () => {
|
||||
let store: StoreMock<AppState>;
|
||||
@@ -191,13 +193,14 @@ describe('CommunityListService', () => {
|
||||
};
|
||||
TestBed.configureTestingModule({
|
||||
providers: [CommunityListService,
|
||||
{ provide: APP_CONFIG, useValue: environment },
|
||||
{ provide: CollectionDataService, useValue: collectionDataServiceStub },
|
||||
{ provide: CommunityDataService, useValue: communityDataServiceStub },
|
||||
{ provide: Store, useValue: StoreMock },
|
||||
],
|
||||
});
|
||||
store = TestBed.inject(Store as any);
|
||||
service = new CommunityListService(communityDataServiceStub, collectionDataServiceStub, store);
|
||||
service = new CommunityListService(environment, communityDataServiceStub, collectionDataServiceStub, store);
|
||||
});
|
||||
|
||||
it('should create', inject([CommunityListService], (serviceIn: CommunityListService) => {
|
||||
|
Reference in New Issue
Block a user