[Po4a-commits] po4a/t 23-man.t,1.3,1.4
Danilo Piazzalunga
po4a-devel@lists.alioth.debian.org
Fri, 25 Feb 2005 13:02:45 +0000
- Previous message: [Po4a-commits] po4a/t/data-23 dot5,NONE,1.1 dot5.it,NONE,1.1 dot5.it.po,NONE,1.1 dot5.pot,NONE,1.1
- Next message: [Po4a-commits] po4a/lib/Locale/Po4a TeX.pm,1.33,1.34
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /cvsroot/po4a/po4a/t
In directory haydn:/tmp/cvs-serv11620/t
Modified Files:
23-man.t
Log Message:
* Rewrite the @tests array construction in t/23-man.t, using t/22-html.t
as an example.
* Add another test case for man pages (dot5).
Index: 23-man.t
===================================================================
RCS file: /cvsroot/po4a/po4a/t/23-man.t,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- 23-man.t 25 Feb 2005 11:54:36 -0000 1.3
+++ 23-man.t 25 Feb 2005 13:02:43 -0000 1.4
@@ -16,63 +16,91 @@
"-I '^\"POT-Creation-Date: ' -I '^\"Content-Transfer-Encoding:'";
my $diff_pod_flags= " -I 'This file was generated by po4a' ";
-# Quotes
-$tests[0]{'run'} = "perl ../po4a-gettextize -f #format# -m data-23/quotes -p tmp/quotes.pot 2>/dev/null";
-$tests[0]{'test'} = "diff -u tmp/quotes.pot data-23/quotes.pot $diff_po_flags";
-$tests[0]{'doc'} = "gettextize well various quotes";
-$tests[1]{'run'} = "cp data-23/quotes.fr.po tmp/ && perl ../po4a-updatepo -f #format# -m data-23/quotes -p tmp/quotes.fr.po >/dev/null 2>&1 ";
-$tests[1]{'test'} = "diff -u $diff_po_flags data-23/quotes.fr.po tmp/quotes.fr.po";
-$tests[1]{'doc'} = "updatepo for this document";
-$tests[2]{'run'} = "perl ../po4a-translate -f #format# -m data-23/quotes -p data-23/quotes.fr.po -l tmp/quotes.fr";
-$tests[2]{'test'} = "diff -u $diff_pod_flags data-23/quotes.fr tmp/quotes.fr";
-$tests[2]{'doc'} = "translate this document";
-
-# Dots
-$tests[3]{'run'} = "perl ../po4a-gettextize -f #format# -m data-23/dot1 -p tmp/dot1.pot 2>/dev/null";
-$tests[3]{'test'} = "diff -u tmp/dot1.pot data-23/dot1.pot $diff_po_flags";
-$tests[3]{'doc'} = "gettextize well various lines beginning by a dot (1)";
-$tests[4]{'run'} = "cp data-23/dot1.fr.po tmp/ && perl ../po4a-updatepo -f #format# -m data-23/dot1 -p tmp/dot1.fr.po >/dev/null 2>&1 ";
-$tests[4]{'test'} = "diff -u $diff_po_flags data-23/dot1.fr.po tmp/dot1.fr.po";
-$tests[4]{'doc'} = "updatepo for this document";
-$tests[5]{'run'} = "perl ../po4a-translate -f #format# -m data-23/dot1 -p data-23/dot1.fr.po -l tmp/dot1.fr";
-$tests[5]{'test'} = "diff -u $diff_pod_flags data-23/dot1.fr tmp/dot1.fr";
-$tests[5]{'doc'} = "translate this document";
-
-$tests[6]{'run'} = "LC_ALL=C perl ../po4a-gettextize -f #format# -m data-23/dot2 -p tmp/dot2.pot 2>tmp/dot2.err || true";
-$tests[6]{'test'} = "diff -u tmp/dot2.err data-23/dot2.err $diff_po_flags";
-$tests[6]{'doc'} = "gettextize well various lines beginning by a dot (2)";
-
-$tests[7]{'run'} = "LC_ALL=C perl ../po4a-gettextize -f #format# -m data-23/dot3 -p tmp/dot3.pot 2>tmp/dot3.err || true";
-$tests[7]{'test'} = "diff -u tmp/dot3.err data-23/dot3.err $diff_po_flags";
-$tests[7]{'doc'} = "gettextize well various lines beginning by a dot (3)";
+# Quotes (3 tests)
+push @tests, {
+ 'run' => "perl ../po4a-gettextize -f #format# -m data-23/quotes -p tmp/quotes.pot 2>/dev/null",
+ 'test' => "diff -u tmp/quotes.pot data-23/quotes.pot $diff_po_flags",
+ 'doc' => "gettextize well various quotes",
+}, {
+ 'run' => "cp data-23/quotes.fr.po tmp/ && perl ../po4a-updatepo -f #format# -m data-23/quotes -p tmp/quotes.fr.po >/dev/null 2>&1 ",
+ 'test' => "diff -u $diff_po_flags data-23/quotes.fr.po tmp/quotes.fr.po",
+ 'doc' => "updatepo for this document",
+}, {
+ 'run' => "perl ../po4a-translate -f #format# -m data-23/quotes -p data-23/quotes.fr.po -l tmp/quotes.fr",
+ 'test' => "diff -u $diff_pod_flags data-23/quotes.fr tmp/quotes.fr",
+ 'doc' => "translate this document",
+};
-$tests[8]{'run'} = "LC_ALL=C perl ../po4a-gettextize -f #format# -m data-23/dot4 -p tmp/dot4.pot 2>tmp/dot4.err || true";
-$tests[8]{'test'} = "diff -u tmp/dot4.err data-23/dot4.err $diff_po_flags";
-$tests[8]{'doc'} = "gettextize well various lines beginning by a dot (4)";
+# Dots (9 tests)
+push @tests, {
+ 'run' => "perl ../po4a-gettextize -f #format# -m data-23/dot1 -p tmp/dot1.pot 2>/dev/null",
+ 'test' => "diff -u tmp/dot1.pot data-23/dot1.pot $diff_po_flags",
+ 'doc' => "gettextize well various lines beginning by a dot (1)",
+}, {
+ 'run' => "cp data-23/dot1.fr.po tmp/ && perl ../po4a-updatepo -f #format# -m data-23/dot1 -p tmp/dot1.fr.po >/dev/null 2>&1 ",
+ 'test' => "diff -u $diff_po_flags data-23/dot1.fr.po tmp/dot1.fr.po",
+ 'doc' => "updatepo for this document",
+}, {
+ 'run' => "perl ../po4a-translate -f #format# -m data-23/dot1 -p data-23/dot1.fr.po -l tmp/dot1.fr",
+ 'test' => "diff -u $diff_pod_flags data-23/dot1.fr tmp/dot1.fr",
+ 'doc' => "translate this document",
+}, {
+ 'run' => "LC_ALL=C perl ../po4a-gettextize -f #format# -m data-23/dot2 -p tmp/dot2.pot 2>tmp/dot2.err || true",
+ 'test' => "diff -u tmp/dot2.err data-23/dot2.err $diff_po_flags",
+ 'doc' => "gettextize well various lines beginning by a dot (2)",
+}, {
+ 'run' => "LC_ALL=C perl ../po4a-gettextize -f #format# -m data-23/dot3 -p tmp/dot3.pot 2>tmp/dot3.err || true",
+ 'test' => "diff -u tmp/dot3.err data-23/dot3.err $diff_po_flags",
+ 'doc' => "gettextize well various lines beginning by a dot (3)",
+}, {
+ 'run' => "LC_ALL=C perl ../po4a-gettextize -f #format# -m data-23/dot4 -p tmp/dot4.pot 2>tmp/dot4.err || true",
+ 'test' => "diff -u tmp/dot4.err data-23/dot4.err $diff_po_flags",
+ 'doc' => "gettextize well various lines beginning by a dot (4)",
+}, {
+ 'run' => "LC_ALL=C perl ../po4a-gettextize -f #format# -m data-23/dot5 -p tmp/dot5.pot 2>/dev/null",
+ 'test' => "diff -u tmp/dot5.pot data-23/dot5.pot $diff_po_flags",
+ 'doc' => "gettextize well various lines beginning by a dot (5)",
+}, {
+ 'run' => "cp data-23/dot5.it.po tmp/ && perl ../po4a-updatepo -f #format# -m data-23/dot5 -p tmp/dot5.it.po >/dev/null 2>&1 ",
+ 'test' => "diff -u $diff_po_flags data-23/dot5.it.po tmp/dot5.it.po",
+ 'doc' => "updatepo for this document",
+}, {
+ 'run' => "perl ../po4a-translate -f #format# -m data-23/dot5 -p data-23/dot5.it.po -l tmp/dot5.it",
+ 'test' => "diff -u $diff_pod_flags data-23/dot5.it tmp/dot5.it",
+ 'doc' => "translate this document",
+};
-# Null argument
-$tests[9]{'run'} = "LC_ALL=C perl ../po4a-gettextize -f #format# -m data-23/null -p tmp/null.pot 2>/dev/null";
-$tests[9]{'test'} = "diff -u tmp/null.pot data-23/null.pot $diff_po_flags";
-$tests[9]{'doc'} = "gettextize well null argument/paragraphs";
-$tests[10]{'run'} = "cp data-23/null.fr.po tmp/ && perl ../po4a-updatepo -f #format# -m data-23/null -p tmp/null.fr.po >/dev/null 2>&1 ";
-$tests[10]{'test'} = "diff -u $diff_po_flags data-23/null.fr.po tmp/null.fr.po";
-$tests[10]{'doc'} = "updatepo for this document";
-$tests[11]{'run'} = "perl ../po4a-translate -f #format# -m data-23/null -p data-23/null.fr.po -l tmp/null.fr";
-$tests[11]{'test'} = "diff -u $diff_pod_flags data-23/null.fr tmp/null.fr";
-$tests[11]{'doc'} = "translate this document";
+# Null argument (3 tests)
+push @tests, {
+ 'run' => "LC_ALL=C perl ../po4a-gettextize -f #format# -m data-23/null -p tmp/null.pot 2>/dev/null",
+ 'test' => "diff -u tmp/null.pot data-23/null.pot $diff_po_flags",
+ 'doc' => "gettextize well null argument/paragraphs",
+}, {
+ 'run' => "cp data-23/null.fr.po tmp/ && perl ../po4a-updatepo -f #format# -m data-23/null -p tmp/null.fr.po >/dev/null 2>&1 ",
+ 'test' => "diff -u $diff_po_flags data-23/null.fr.po tmp/null.fr.po",
+ 'doc' => "updatepo for this document",
+}, {
+ 'run' => "perl ../po4a-translate -f #format# -m data-23/null -p data-23/null.fr.po -l tmp/null.fr",
+ 'test' => "diff -u $diff_pod_flags data-23/null.fr tmp/null.fr",
+ 'doc' => "translate this document",
+};
-# Escaped tabs and newlines
-$tests[12]{'run'} = "LC_ALL=C perl ../po4a-gettextize -f #format# -m data-23/escapes1 -p tmp/escapes1.pot 2>/dev/null";
-$tests[12]{'test'} = "diff -u tmp/escapes1.pot data-23/escapes1.pot $diff_po_flags";
-$tests[12]{'doc'} = "gettextize well escaped newlines and tabs";
-$tests[13]{'run'} = "cp data-23/escapes1.it.po tmp/ && perl ../po4a-updatepo -f #format# -m data-23/escapes1 -p tmp/escapes1.it.po >/dev/null 2>&1 ";
-$tests[13]{'test'} = "diff -u $diff_po_flags data-23/escapes1.it.po tmp/escapes1.it.po";
-$tests[13]{'doc'} = "updatepo for this document";
-$tests[14]{'run'} = "perl ../po4a-translate -f #format# -m data-23/escapes1 -p data-23/escapes1.it.po -l tmp/escapes1.it";
-$tests[14]{'test'} = "diff -u $diff_pod_flags data-23/escapes1.it tmp/escapes1.it";
-$tests[14]{'doc'} = "translate this document";
+# Escaped tabs and newlines (3 tests)
+push @tests, {
+ 'run' => "LC_ALL=C perl ../po4a-gettextize -f #format# -m data-23/escapes1 -p tmp/escapes1.pot 2>/dev/null",
+ 'test' => "diff -u tmp/escapes1.pot data-23/escapes1.pot $diff_po_flags",
+ 'doc' => "gettextize well escaped newlines and tabs",
+}, {
+ 'run' => "cp data-23/escapes1.it.po tmp/ && perl ../po4a-updatepo -f #format# -m data-23/escapes1 -p tmp/escapes1.it.po >/dev/null 2>&1 ",
+ 'test' => "diff -u $diff_po_flags data-23/escapes1.it.po tmp/escapes1.it.po",
+ 'doc' => "updatepo for this document",
+}, {
+ 'run' => "perl ../po4a-translate -f #format# -m data-23/escapes1 -p data-23/escapes1.it.po -l tmp/escapes1.it",
+ 'test' => "diff -u $diff_pod_flags data-23/escapes1.it tmp/escapes1.it",
+ 'doc' => "translate this document",
+};
-use Test::More tests =>30; # $formats * $tests * 2
+use Test::More tests => 36; # $formats * $tests * 2
foreach my $format (@formats) {
for (my $i=0; $i<scalar @tests; $i++) {
- Previous message: [Po4a-commits] po4a/t/data-23 dot5,NONE,1.1 dot5.it,NONE,1.1 dot5.it.po,NONE,1.1 dot5.pot,NONE,1.1
- Next message: [Po4a-commits] po4a/lib/Locale/Po4a TeX.pm,1.33,1.34
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]