1
0
mirror of synced 2026-01-19 01:07:28 +00:00
steve a50161f0ab 2005-12-17 15:21:32 by steve
imported into cvstrac
2005-12-17 15:21:32 +00:00

33 lines
605 B
Bash
Executable File

#!/bin/sh
#
# Automatically attempt to create a test which ensures all the modules
# used in the code are availabe.
#
# Steve
# --
# http://www.steve.org.uk/
#
# $Id: modules.sh,v 1.2 2005-12-17 15:21:32 steve Exp $
#
cat <<EOF
#!/usr/bin/perl -w -I..
#
# Test that all the Perl modules we require are available.
#
# This list is automatically generated by modules.sh
#
use Test::More qw( no_plan );
EOF
for i in `rgrep '^use ' .. | awk '{print $2}' | tr -d
\;\(\) | sort | uniq`; \
do \
echo "BEGIN{ use_ok( '$i' ); }"; \
echo "require_ok( '$i' );" ; \
echo -e "\n" ; \
done