Photo implements one method per PhotoExif field
check / check (push) Successful in 1m46s

Photo now implements a mapped type with one method per PhotoExif field,
each taking exif()'s options and giving that field's type, so the
build's type check fails when PhotoExif has a field Photo has no method
for, whatever the test fixtures hold. The test comment and TODO.md say
so.

Model: opus-5-5
This commit is contained in:
2026-10-01 21:11:05 +00:00
parent b669df220a
commit 4986ebd889
3 changed files with 16 additions and 3 deletions
+4
View File
@@ -462,6 +462,10 @@ describe("Photo save path, local copy, content and EXIF", () => {
await lib.close();
});
// The build's type check, not this test, makes sure `Photo` has a method
// for every `PhotoExif` field, whatever the fixtures hold: `Photo`
// implements a type with one method per field. This test checks that each
// method gives the same value as exif().
it.each([
["JPEG", JPEG_WITH_EXIF],
["HEIC", HEIC_WITH_EXIF],