import { describe, it, expect } from 'vitest'; import { decodeHtmlEntities } from './utils'; describe('decodeHtmlEntities', () => { it('decodes < and > to < and >', () => { expect(decodeHtmlEntities('<b>bold</b>')).toBe('bold'); }); it('decodes & to &', () => { expect(decodeHtmlEntities('Tom & Jerry')).toBe('Tom & Jerry'); }); it('decodes " and ' to quote characters', () => { expect(decodeHtmlEntities('"hello" 'world'')).toBe(`"hello" 'world'`); }); it('decodes numeric entities', () => { expect(decodeHtmlEntities('<div>')).toBe('