Fix broken test suite and untrack runtime artifacts
- Bridge jsdom localStorage/sessionStorage over Node 22+'s experimental globals that vitest's jsdom environment doesn't override - Update Greek lookup tests to mock the OpenScriptures Strong's dictionary instead of the retired bolls.life path - Update migrateChunk no-op test for backfilled fields - Match en-dash verse range labels in chunk creation test - Untrack .api.log/.api.pid and gitignore them Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
+9
-2
@@ -263,9 +263,16 @@ describe('migrateChunk', () => {
|
||||
expect(result.crossReferences).toEqual([]);
|
||||
});
|
||||
|
||||
test('is a no-op when chunk already has observation field', () => {
|
||||
test('preserves existing fields and backfills new ones when chunk already has observation field', () => {
|
||||
const modern = { id: 'c1', startVerse: 1, endVerse: 1, observation: 'Already migrated.', interpretation: '', application: '', crossReferences: [], greekWords: [] };
|
||||
expect(migrateChunk(modern)).toBe(modern);
|
||||
const result = migrateChunk(modern);
|
||||
expect(result).toMatchObject(modern);
|
||||
expect(result.tags).toEqual([]);
|
||||
expect(result.spilloverEndVerse).toBeNull();
|
||||
expect(result.generalNotes).toBe('');
|
||||
expect(result.episodeNumber).toBe('');
|
||||
expect(result.episodeTitle).toBe('');
|
||||
expect(result.finalScript).toBe('');
|
||||
});
|
||||
|
||||
test('handles missing notes gracefully', () => {
|
||||
|
||||
Reference in New Issue
Block a user