From: Gavin Carr Date: Fri, 18 Jun 2010 16:59:08 +0000 (+0100) Subject: Add symlink test cases, remove obsolete test infrastructure. X-Git-Url: https://git.stderr.nl/gitweb?a=commitdiff_plain;h=c9cb3b468f663d655cbc82fd6f60510836f10796;p=matthijs%2Fupstream%2Fblosxom.git Add symlink test cases, remove obsolete test infrastructure. Add symlink test cases, since we're now using a VCS that supports symlinks! Therefore remove obsolete Setup and Tests infrastructure files. Add a Makefile to let us just to 'make' or 'make test' in the test directory. --- diff --git a/t/01_templates.t b/t/01_templates.t new file mode 120000 index 0000000..e42f284 --- /dev/null +++ b/t/01_templates.t @@ -0,0 +1 @@ +driver \ No newline at end of file diff --git a/t/02_smoketest.t b/t/02_smoketest.t new file mode 120000 index 0000000..e42f284 --- /dev/null +++ b/t/02_smoketest.t @@ -0,0 +1 @@ +driver \ No newline at end of file diff --git a/t/03_interpolate.t b/t/03_interpolate.t new file mode 120000 index 0000000..e42f284 --- /dev/null +++ b/t/03_interpolate.t @@ -0,0 +1 @@ +driver \ No newline at end of file diff --git a/t/03_permalinks.t b/t/03_permalinks.t new file mode 120000 index 0000000..e42f284 --- /dev/null +++ b/t/03_permalinks.t @@ -0,0 +1 @@ +driver \ No newline at end of file diff --git a/t/04_plugin_dir.t b/t/04_plugin_dir.t new file mode 120000 index 0000000..e42f284 --- /dev/null +++ b/t/04_plugin_dir.t @@ -0,0 +1 @@ +driver \ No newline at end of file diff --git a/t/04_plugin_list.t b/t/04_plugin_list.t new file mode 120000 index 0000000..e42f284 --- /dev/null +++ b/t/04_plugin_list.t @@ -0,0 +1 @@ +driver \ No newline at end of file diff --git a/t/08_static_basic.t b/t/08_static_basic.t new file mode 120000 index 0000000..e42f284 --- /dev/null +++ b/t/08_static_basic.t @@ -0,0 +1 @@ +driver \ No newline at end of file diff --git a/t/Makefile b/t/Makefile new file mode 100644 index 0000000..6caa89e --- /dev/null +++ b/t/Makefile @@ -0,0 +1,6 @@ + +all: test + +test: + prove *.t + diff --git a/t/README b/t/README index 53ea291..e8fdbdb 100644 --- a/t/README +++ b/t/README @@ -1,7 +1,6 @@ Running Tests ============= - perl ./Setup prove *.t @@ -11,10 +10,8 @@ Test Layout To add a new test, you want to add two things - a test script (which is typically just a symlink to the main 'driver' script), and a test -directory. If you just want a symlink test script, then add your -test script name to 'Tests', and rerun Setup. To add a new test -directory, you're probably best just to copy one of the existing -ones - 'templates' is a good choice: +directory. To add a new test directory, you're probably best just to +copy one of the existing ones - 'templates' is a good choice: cp -rp templates newtest diff --git a/t/Setup b/t/Setup deleted file mode 100755 index 93f0733..0000000 --- a/t/Setup +++ /dev/null @@ -1,27 +0,0 @@ -#!/usr/bin/env perl -# -# Script to setup test script symlinks, since CVS can't store them -# - -use strict; -use IO::File; - -my $DRIVER = 'driver'; -my $TESTS = 'Tests'; -die "cannot find driver file '$DRIVER'" unless -f $DRIVER; -die "cannot find tests file '$TESTS'" unless -f $TESTS; - -my @tests = (); - -my $th = IO::File->new($TESTS, 'r') - or die "cannot open tests file '$TESTS': $!"; -@tests = <$th>; -close $th; - -for my $t (@tests) { - chomp $t; - unlink $t if -l $t; - print "symlink $DRIVER $t\n"; - eval { symlink $DRIVER, $t } or die "symlink $DRIVER, $t failed: $!"; -} - diff --git a/t/Tests b/t/Tests deleted file mode 100644 index 0a999a3..0000000 --- a/t/Tests +++ /dev/null @@ -1,7 +0,0 @@ -01_templates.t -02_smoketest.t -03_permalinks.t -03_interpolate.t -04_plugin_dir.t -04_plugin_list.t -08_static_basic.t