diff --git a/test/utils/common-utils.js b/test/utils/common-utils.js index 8e40dcacd4..66b51e7722 100644 --- a/test/utils/common-utils.js +++ b/test/utils/common-utils.js @@ -1,27 +1,7 @@ const utils = require('../../lib/utils/common-utils'); -const cheerio = require('cheerio'); describe('common-utils', () => { it('toTitleCase', async () => { expect(utils.toTitleCase('RSSHub IS AS aweSOme aS henry')).toBe('Rsshub Is As Awesome As Henry'); }); - - it('handleImg', async () => { - const testSet = [ - '

',
- '
',
- '
',
- ];
- testSet.forEach((htmlStr, index) => {
- const $ = cheerio.load(htmlStr);
- utils.handleImg($);
- const result = $('div').html();
- expect(result).toBe(expectList[index]);
- });
- });
});