Fixed functions to get tags and aliases

This commit is contained in:
Simon Cambier
2022-10-22 20:55:48 +02:00
parent 9beed2311f
commit 6c80b759ff
3 changed files with 14 additions and 46 deletions

View File

@@ -19,7 +19,7 @@ describe('Utils', () => {
// Arrange
const metadata = {
frontmatter: { aliases: ['foo', 'bar'] },
} as CachedMetadata
} as unknown as CachedMetadata
// Act
const actual = getAliasesFromMetadata(metadata)
// Assert
@@ -29,7 +29,7 @@ describe('Utils', () => {
// Arrange
const metadata = {
frontmatter: { aliases: 'foo, bar' },
} as CachedMetadata
} as unknown as CachedMetadata
// Act
const actual = getAliasesFromMetadata(metadata)
// Assert
@@ -39,7 +39,7 @@ describe('Utils', () => {
// Arrange
const metadata = {
frontmatter: { aliases: '' },
} as CachedMetadata
} as unknown as CachedMetadata
// Act
const actual = getAliasesFromMetadata(metadata)
// Assert