diff --git a/plugins/catalog-backend/src/service/DefaultEntitiesCatalog.test.ts b/plugins/catalog-backend/src/service/DefaultEntitiesCatalog.test.ts index 43e208197f..7094cfd1c2 100644 --- a/plugins/catalog-backend/src/service/DefaultEntitiesCatalog.test.ts +++ b/plugins/catalog-backend/src/service/DefaultEntitiesCatalog.test.ts @@ -469,62 +469,6 @@ describe('DefaultEntitiesCatalog', () => { expect(entities.length).toBe(0); }, ); - - it.each(databases.eachSupportedId())( - 'should return both target and targetRef for entities', - async databaseId => { - const { knex } = await createDatabase(databaseId); - await addEntity( - knex, - { - apiVersion: 'a', - kind: 'k', - metadata: { name: 'one' }, - spec: {}, - relations: [{ type: 'r', targetRef: 'x:y/z' } as any], - }, - [], - ); - await addEntity( - knex, - { - apiVersion: 'a', - kind: 'k', - metadata: { name: 'two' }, - spec: {}, - relations: [ - { - type: 'r', - target: { kind: 'x', namespace: 'y', name: 'z' }, - } as any, - ], - }, - [], - ); - const catalog = new DefaultEntitiesCatalog(knex); - - const { entities } = await catalog.entities(); - - expect( - entities.find(e => e.metadata.name === 'one')!.relations, - ).toEqual([ - { - type: 'r', - targetRef: 'x:y/z', - target: { kind: 'x', namespace: 'y', name: 'z' }, - }, - ]); - expect( - entities.find(e => e.metadata.name === 'two')!.relations, - ).toEqual([ - { - type: 'r', - targetRef: 'x:y/z', - target: { kind: 'x', namespace: 'y', name: 'z' }, - }, - ]); - }, - ); }); describe('removeEntityByUid', () => { diff --git a/plugins/catalog-backend/src/stitching/Stitcher.test.ts b/plugins/catalog-backend/src/stitching/Stitcher.test.ts index 582ed3f953..9accebf1fc 100644 --- a/plugins/catalog-backend/src/stitching/Stitcher.test.ts +++ b/plugins/catalog-backend/src/stitching/Stitcher.test.ts @@ -94,11 +94,6 @@ describe('Stitcher', () => { { type: 'looksAt', targetRef: 'k:ns/other', - target: { - kind: 'k', - namespace: 'ns', - name: 'other', - }, }, ], apiVersion: 'a', @@ -160,20 +155,10 @@ describe('Stitcher', () => { { type: 'looksAt', targetRef: 'k:ns/other', - target: { - kind: 'k', - namespace: 'ns', - name: 'other', - }, }, { type: 'looksAt', targetRef: 'k:ns/third', - target: { - kind: 'k', - namespace: 'ns', - name: 'third', - }, }, ]), apiVersion: 'a',