Add ARM files
[dh-make-perl] / dev / arm / libhtml-tree-perl / libhtml-tree-perl-3.23 / t / clonei.t
diff --git a/dev/arm/libhtml-tree-perl/libhtml-tree-perl-3.23/t/clonei.t b/dev/arm/libhtml-tree-perl/libhtml-tree-perl-3.23/t/clonei.t
new file mode 100644 (file)
index 0000000..a32bf15
--- /dev/null
@@ -0,0 +1,19 @@
+#!perl -Tw
+
+use strict;
+use Test::More tests => 4;
+BEGIN {use_ok ( "HTML::TreeBuilder");}
+
+my $t = HTML::TreeBuilder->new;
+$t->parse('stuff <em name="foo">lalal</em>');
+$t->eof;
+my $c = $t->clone();
+
+#these are correct tests. Of what, I'm not sure.
+ok($c->same_as($t), "\$c is the same as \$t, according to HTML::Element");
+ok($t->same_as($c), "\$t is the same as \$c, according to HTML::Element");
+
+$c->delete();
+ok ($t->find_by_attribute('name', 'foo'), "My name is foo after delete" );
+
+$t->delete();