mirror of
https://github.com/luxfi/pics.git
synced 2026-10-30 15:22:15 +00:00
10 lines
362 B
JavaScript
10 lines
362 B
JavaScript
const fortune = require('./fortune.js');
|
|
|
|
describe('fortune markdown', () => {
|
|
test('should contain a random fortune for an input of ##fortune', () => {
|
|
const output = '##fortune'.replace(fortune.regex, fortune.markdown.bind(null, false));
|
|
const hasFortuneText = fortune.fortunes.some(f => output.includes(f));
|
|
expect(hasFortuneText).toBe(true);
|
|
});
|
|
});
|