use strict;
use warnings;
-use Test::More tests => 10 + 2 * 7;
+use Test::More tests => 11 + 2 * 8;
use LaTeX::TikZ;
\end{scope}
RES
+my $poly = Tikz->closed_polyline(
+ [ 0, 0 ], [ 1, 0 ], [ 1, 1 ], [ 0, 1 ]
+);
+
+my $poly2 = eval {
+ $poly->$translate(Tikz->point(-1, 1));
+};
+is $@, '', 'translating a polyline doesn\'t croak';
+
+check $poly2, 'the translated polyline', <<'RES';
+\draw (-1cm,1cm) -- (0cm,1cm) -- (0cm,2cm) -- (-1cm,2cm) -- cycle ;
+RES
+
my $strip = eval {
Tikz->functor(
'+LaTeX::TikZ::Mod' => sub { return },