Update of /cvsroot/compbench/CompBenchmarks++/CBM-PI/t/lib
In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv10007
Added Files:
libtest.pl Makefile.am
Log Message:
First import.
--- NEW FILE: Makefile.am ---
data_DATA = libtest.pl
--- NEW FILE: libtest.pl ---
# -----------------------------------------------------------------------------
# $Id: libtest.pl,v 1.1 2006/12/28 18:51:42 xfred Exp $
#
# Description : Various utility functions for testsuite.
#
# This is free software.
# For details, see the GNU Public License in the COPYING file, or
# Look http://www.fsf.org
# -----------------------------------------------------------------------------
our $top_srcdir = $0;
$top_srcdir =~ s/(.+)\/.*/$1/;
sub check_simple {
my $str = shift;
ok($str ne "");
if ($str =~ /\n/) {
ok(0);
} else {
ok(1);
}
if ($str =~ /^ +(.*)/) {
ok(0, "'$str' starts with space(s)");
} else {
ok(1);
}
if ($str =~ / $/) {
ok(0, "'$str' ends with space(s)");
} else {
ok(1);
}
}
1;
|