Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/feeds/rss/common/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ export namespace Rss {

export type Source = {
title: string
url?: string
url: string
}

export type Item<TDate extends DateLike> = {
Expand Down
4 changes: 3 additions & 1 deletion src/feeds/rss/generate/utils.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -370,12 +370,14 @@ describe('generateSource', () => {
expect(generateSource(value)).toEqual(expected)
})

it('should generate source with minimal properties', () => {
it('should generate source with all required properties', () => {
const value = {
title: 'Example Source',
url: 'https://example.com/feed.xml',
}
const expected = {
'#text': 'Example Source',
'@url': 'https://example.com/feed.xml',
}

expect(generateSource(value)).toEqual(expected)
Expand Down