Description:
In tests.yml L86-L88 and L139-L142, the inline CI test scripts use url instead of loc for SitemapIndexEntry objects:
const validIndexPayload = [
{ url: 'https://fomadev.com/sitemap-products.xml', lastmod: new Date() },
// ^-- Should be `loc` per the SitemapIndexEntry interface
];
This works only because index-builder.ts L30 has an undocumented fallback: const targetLoc = entry.loc || (entry as any).url || ''. While this resilience is nice at runtime, using url in official CI tests is misleading and masks the real API contract.
Description:
In
tests.ymlL86-L88 and L139-L142, the inline CI test scripts useurlinstead oflocforSitemapIndexEntryobjects:This works only because
index-builder.tsL30 has an undocumented fallback:const targetLoc = entry.loc || (entry as any).url || ''. While this resilience is nice at runtime, usingurlin official CI tests is misleading and masks the real API contract.