25 lines
816 B
TypeScript
25 lines
816 B
TypeScript
import { fallbackCreditsContent, isCreditsContent } from '../src/data';
|
|
|
|
describe('credits data', () => {
|
|
it('provides valid fallback credits content', () => {
|
|
expect(isCreditsContent(fallbackCreditsContent)).toBe(true);
|
|
expect(fallbackCreditsContent.mainLogo.title).toBe('Throne of the Bone King');
|
|
expect(fallbackCreditsContent.contributors.length).toBeGreaterThan(0);
|
|
expect(fallbackCreditsContent.technologies.length).toBeGreaterThan(0);
|
|
expect(fallbackCreditsContent.specialThanks.length).toBeGreaterThan(0);
|
|
});
|
|
|
|
it('rejects malformed credits content', () => {
|
|
expect(
|
|
isCreditsContent({
|
|
contributors: [],
|
|
mainLogo: {
|
|
title: 'Missing subtitle',
|
|
},
|
|
specialThanks: [],
|
|
technologies: [],
|
|
}),
|
|
).toBe(false);
|
|
});
|
|
});
|