From 203d1f31cb569fa470d86e25298566dd5014e24b Mon Sep 17 00:00:00 2001 From: Daniel Dietzler Date: Wed, 17 Jul 2024 22:31:18 +0200 Subject: [PATCH] chore: e2e test --- e2e/src/api/specs/asset.e2e-spec.ts | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/e2e/src/api/specs/asset.e2e-spec.ts b/e2e/src/api/specs/asset.e2e-spec.ts index d0cf0c492c66b6..c67400f2ea93bc 100644 --- a/e2e/src/api/specs/asset.e2e-spec.ts +++ b/e2e/src/api/specs/asset.e2e-spec.ts @@ -507,6 +507,21 @@ describe('/asset', () => { expect(status).toEqual(200); }); + it('should geocode gps data without city', async () => { + const { status, body } = await request(app) + .put(`/assets/${user1Assets[0].id}`) + .set('Authorization', `Bearer ${user1.accessToken}`) + .send({ latitude: 69, longitude: 42 }); + + await utils.waitForQueueFinish(admin.accessToken, 'metadataExtraction'); + + expect(body).toMatchObject({ + id: user1Assets[0].id, + exifInfo: expect.objectContaining({ city: undefined, country: 'Kazakhstan' }), + }); + expect(status).toEqual(200); + }); + it('should set the description', async () => { const { status, body } = await request(app) .put(`/assets/${user1Assets[0].id}`)