Add the following packages libalgorithm-diff-perl libspiffy-perl libtext-diff-perl...
[pkg-perl] / deb-src / libtest-base-perl / libtest-base-perl-0.54 / t / spec_string.t
diff --git a/deb-src/libtest-base-perl/libtest-base-perl-0.54/t/spec_string.t b/deb-src/libtest-base-perl/libtest-base-perl-0.54/t/spec_string.t
new file mode 100644 (file)
index 0000000..2931fd0
--- /dev/null
@@ -0,0 +1,29 @@
+use Test::Base;
+
+filters 'chomp';
+spec_string <<'...';
+===
+--- foo
+1
+--- bar
+2
+===
+--- foo
+3
+--- bar
+4
+...
+
+plan tests => 3 * blocks;
+
+run {
+    my $block = shift;
+    is ref($block), 'Test::Base::Block';
+};
+
+my @blocks = blocks;
+
+is $blocks[0]->foo, 1;
+is $blocks[0]->bar, 2;
+is $blocks[1]->foo, 3;
+is $blocks[1]->bar, 4;