use strict;
use warnings;
-use utf8;
use Test::More;
-use DOM::Tiny::Entities qw(html_unescape xml_escape);
-use Encode 'decode';
+use DOM::Tiny::Entities ();
-# html_unescape
-is html_unescape('<foo>bar<baz>&"'),
- "<foo>bar<baz>&\"", 'right HTML unescaped result';
-
-# html_unescape (special entities)
-is html_unescape('foo ☃ ∳ bar ¹baz'),
- "foo ☃ \x{2233} bar ¹baz", 'right HTML unescaped result';
-
-# html_unescape (multi-character entity)
-is html_unescape(decode 'UTF-8', '∾̳'), "\x{223e}\x{0333}",
- 'right HTML unescaped result';
-
-# html_unescape (apos)
-is html_unescape('foobar'<baz>&"'), "foobar'<baz>&\"",
- 'right HTML unescaped result';
-
-# html_unescape (nothing to unescape)
-is html_unescape('foobar'), 'foobar', 'right HTML unescaped result';
-
-# html_unescape (UTF-8)
-is html_unescape(decode 'UTF-8', 'foo<baz>&"Œ&Foo;'),
- "foo<baz>&\"\x{152}&Foo;", 'right HTML unescaped result';
-
-# xml_escape
-is xml_escape(qq{la<f>\nbar"baz"'yada\n'<la}),
- "la<f>\nbar"baz"'yada\n'&lt;la",
- 'right XML escaped result';
-
-# xml_escape (UTF-8 with nothing to escape)
-is xml_escape('привет'), 'привет', 'right XML escaped result';
-
-# xml_escape (UTF-8)
-is xml_escape('привет<foo>'), 'привет<foo>',
- 'right XML escaped result';
+is(\&DOM::Tiny::Entities::html_escape, \&Mojo::DOM58::Entities::html_escape);
+is(\&DOM::Tiny::Entities::html_unescape, \&Mojo::DOM58::Entities::html_unescape);
done_testing;