mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-08 18:44:14 +00:00
65272: Existing test fixes
This commit is contained in:
@@ -57,7 +57,7 @@ export abstract class AbstractItemUpdateComponent implements OnInit {
|
|||||||
*/
|
*/
|
||||||
ngOnInit(): void {
|
ngOnInit(): void {
|
||||||
observableCombineLatest(this.route.data, this.route.parent.data).pipe(
|
observableCombineLatest(this.route.data, this.route.parent.data).pipe(
|
||||||
map(([data, parentData]) => Object.assign(data, parentData)),
|
map(([data, parentData]) => Object.assign({}, data, parentData)),
|
||||||
map((data) => data.item),
|
map((data) => data.item),
|
||||||
first(),
|
first(),
|
||||||
map((data: RemoteData<Item>) => data.payload)
|
map((data: RemoteData<Item>) => data.payload)
|
||||||
|
@@ -123,6 +123,7 @@ describe('ItemMetadataComponent', () => {
|
|||||||
commitUpdates: {}
|
commitUpdates: {}
|
||||||
});
|
});
|
||||||
routeStub = {
|
routeStub = {
|
||||||
|
data: observableOf({}),
|
||||||
parent: {
|
parent: {
|
||||||
data: observableOf({ item: createSuccessfulRemoteDataObject(item) })
|
data: observableOf({ item: createSuccessfulRemoteDataObject(item) })
|
||||||
}
|
}
|
||||||
|
@@ -122,6 +122,7 @@ describe('ItemRelationshipsComponent', () => {
|
|||||||
findById: observableOf(new RemoteData(false, false, true, undefined, item))
|
findById: observableOf(new RemoteData(false, false, true, undefined, item))
|
||||||
});
|
});
|
||||||
routeStub = {
|
routeStub = {
|
||||||
|
data: observableOf({}),
|
||||||
parent: {
|
parent: {
|
||||||
data: observableOf({ item: new RemoteData(false, false, true, null, item) })
|
data: observableOf({ item: new RemoteData(false, false, true, null, item) })
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user