import htmlToJSX from './htmlToJSX'; describe('htmlToJSX', () => { describe('html attributes', function() { test('class should be repleaced with className', function() { expect(htmlToJSX('
')).toEqual('
'); }); test('for should be repleaced with htmlFor', function() { expect(htmlToJSX('')).toEqual(''); }); test('attributes should be camelCased', function() { expect(htmlToJSX('')).toEqual( '', ); }); }); describe('html tags', function() { test('should have root element', function() { expect(htmlToJSX('
foo
bar
')).toEqual( '
foo
bar
', ); }); test('should have backslash', function() { expect(htmlToJSX('


foo
')).toEqual( '


foo
', ); }); test('close tag', () => { expect(htmlToJSX(``)).toEqual(``); }); test('close tag', () => { expect(htmlToJSX(``)).toEqual(``); }); test('style tag', () => { expect(htmlToJSX(``)).toEqual( "