fix unit tests

This commit is contained in:
Ben Irvin 2022-12-21 15:34:56 +01:00
parent ecfbe42ae2
commit 06b87fca54
2 changed files with 8 additions and 2 deletions

View File

@ -46,10 +46,13 @@ describe('Local Strapi Source Provider - Entities Streaming', () => {
{ id: 2, age: 84 },
],
});
const contentTypes = getContentTypes();
const strapi = getStrapiFactory({
contentTypes: getContentTypes(),
contentTypes,
db: { queryBuilder },
getModel: jest.fn((uid) => {
return contentTypes[uid];
}),
})();
const entitiesStream = createEntitiesStream(strapi);

View File

@ -95,6 +95,9 @@ describe('Local Strapi Source Provider', () => {
db: {
queryBuilder,
},
getModel: jest.fn((uid) => {
return contentTypes[uid];
}),
}),
});