summaryrefslogtreecommitdiff
path: root/examples/qtest/invert-images.test
diff options
context:
space:
mode:
Diffstat (limited to 'examples/qtest/invert-images.test')
-rw-r--r--examples/qtest/invert-images.test32
1 files changed, 32 insertions, 0 deletions
diff --git a/examples/qtest/invert-images.test b/examples/qtest/invert-images.test
new file mode 100644
index 0000000..0dc15a2
--- /dev/null
+++ b/examples/qtest/invert-images.test
@@ -0,0 +1,32 @@
+#!/usr/bin/env perl
+require 5.008;
+BEGIN { $^W = 1; }
+use strict;
+
+chdir("invert-images") or die "chdir testdir failed: $!\n";
+
+require TestDriver;
+
+my $td = new TestDriver('invert-images');
+
+cleanup();
+
+$td->runtest("double page size",
+ {$td->COMMAND => "pdf-invert-images in.pdf a.pdf"},
+ {$td->STRING =>
+ "pdf-invert-images: new file written to a.pdf\n",
+ $td->EXIT_STATUS => 0},
+ $td->NORMALIZE_NEWLINES);
+
+$td->runtest("check output",
+ {$td->FILE => "a.pdf"},
+ {$td->FILE => "out.pdf"});
+
+cleanup();
+
+$td->report(2);
+
+sub cleanup
+{
+ unlink 'a.pdf';
+}