From d8c064857fc8ac0c1bc3d7fc2c2f74a606324835 Mon Sep 17 00:00:00 2001 From: kagahd Date: Tue, 12 Mar 2024 08:48:55 +0100 Subject: [PATCH] re-enable unit test that keywords from photo are merged with keywords from sidecar --- .../assets/sidecar/metadata.jpg_original | Bin 4489 -> 0 bytes test/backend/assets/sidecar/metadata_v2.jpg | Bin 4489 -> 5095 bytes .../assets/sidecar/metadata_v2.jpg.json | 4 ++-- .../model/threading/MetaDataLoader.spec.ts | 3 ++- 4 files changed, 4 insertions(+), 3 deletions(-) delete mode 100644 test/backend/assets/sidecar/metadata.jpg_original diff --git a/test/backend/assets/sidecar/metadata.jpg_original b/test/backend/assets/sidecar/metadata.jpg_original deleted file mode 100644 index c3d685e8df29ddfb9a23c6594e593a328e74acc1..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 4489 zcmeHKS!^3c7@j?RZ7YZy*GUa1+jWyV5%#V(Nn5XMhbE~TR|?8eXn?2ndTnoFd)@U0 zyOt12ISRama=(Rg_N|n1K0u+IZ!K4k7s64Fhtfd9Q4nU~EPf7}c7(zqfFKAMf$0|fqa zu-^bX%dkBh!*c9q(z}K8_Hw=5a8_#=z>qT52uBE7wkM&DR_s|+!@)hP^MFuogW?%5 z0F1c7Xuyp|gVAI%nu#WYuviG&RadWWYO%Gpw%F`;$93&(j%%FP+U?}^q_bmVXIJOC zHaFvTG3~BSmlgyunM{P4XeNkem&5LG{o_`A6Iji_00<1B0BS`rD^ffL+F+grsG25R zr6DK=^EH_*#3~3l(gaWh!%!SE7;qe-?||z7w;I;0_ii;dkMbsJw~d{doijW84;@`Q zcKrN??ufG2LfBhc*E!ldHo7{ydU`i)-s0m12DgQ_4~2J(@4V^eT@$z5Dn!LtJRwbH z)#=-F`8|cZ?!M>VefQn}z=QiAdiaq?AA9_XCl5UJ^fS*s_x!;Z4!?NhrI%lM^|iO& zKK9PL@4f%QhbKPz_>)gRJ9+B#{1;z-_4V0rzWwg|g&%*qu=w*Yzy5Y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*!_-pH-<`$=+_`n_4CSHocIl diff --git a/test/backend/assets/sidecar/metadata_v2.jpg.json b/test/backend/assets/sidecar/metadata_v2.jpg.json index 5c544af4..e66ce699 100644 --- a/test/backend/assets/sidecar/metadata_v2.jpg.json +++ b/test/backend/assets/sidecar/metadata_v2.jpg.json @@ -3,8 +3,8 @@ "width": 10, "height": 5 }, - "creationDate": 1709057753000, - "fileSize": 4489, + "creationDate": 1710188754000, + "fileSize": 5095, "keywords": [ "floor", "book", diff --git a/test/backend/unit/model/threading/MetaDataLoader.spec.ts b/test/backend/unit/model/threading/MetaDataLoader.spec.ts index 298c6582..e0b0b8c6 100644 --- a/test/backend/unit/model/threading/MetaDataLoader.spec.ts +++ b/test/backend/unit/model/threading/MetaDataLoader.spec.ts @@ -155,7 +155,8 @@ describe('MetadataLoader', () => { it('should merge keywords from photo with keywords from sidecar', async () => { const data = await MetadataLoader.loadPhotoMetadata(path.join(__dirname, '/../../../assets/sidecar/metadata_v2.jpg')); - const expected = require(path.join(__dirname, '/../../../assets/sidecar/metadata_v2.jpg.json')); //"metadata_v2.jpg" is identical to "metadata.jpg" and "metadata_v2.xmp" contains 2 different keywords expect(Utils.clone(data)).to.be.deep.equal(expected); + const expected = require(path.join(__dirname, '/../../../assets/sidecar/metadata_v2.jpg.json')); //"metadata_v2.jpg" is identical to "metadata.jpg" and "metadata_v2.xmp" contains 2 different keywords + expect(Utils.clone(data)).to.be.deep.equal(expected); });