Skip to content

Commit

Permalink
handles nits from PR review
Browse files Browse the repository at this point in the history
  • Loading branch information
TinaHeiligers committed Sep 19, 2022
1 parent 0ce4a5d commit 7aa18ba
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2454,7 +2454,7 @@ describe('SavedObjectsRepository', () => {
);
});

it(`returns an for an object when the object's type is hidden`, async () => {
it(`returns an error for an object when the object's type is hidden`, async () => {
const hiddenObject = { ...obj1, type: HIDDEN_TYPE };
await repositoryBulkDeleteError(hiddenObject, false, expectErrorInvalidType(hiddenObject));
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ export class SavedObjectsRepository implements ISavedObjectsRepository {
serializer,
migrator,
allowedTypes = [],
logger, // 'savedobjects-service.repository'
logger,
} = options;

// It's important that we migrate documents / mark them as up-to-date
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -263,8 +263,11 @@ describe('404s from proxies', () => {
});

it('handles `bulkDelete` requests that are successful when the proxy passes through the product header', async () => {
const docsToGet = myBulkDeleteTypeDocs;
const bulkDeleteDocs = docsToGet.map((doc) => ({ id: doc.id, type: 'my_bulk_delete_type' }));
const docsToDelete = myBulkDeleteTypeDocs;
const bulkDeleteDocs = docsToDelete.map((doc) => ({
id: doc.id,
type: 'my_bulk_delete_type',
}));

const docsFound = await repository.bulkDelete(bulkDeleteDocs, { force: false });
expect(docsFound.statuses.length).toBeGreaterThan(0);
Expand Down

0 comments on commit 7aa18ba

Please sign in to comment.