09-27-2004
10 More Discussions You Might Find Interesting
1. News, Links, Events and Announcements
A goofy UNIX test:
http://www.majon.com/cgi-bin/IQ?Q=unix
WARNING: ANSWERS ARE BELOW!!!!
IF YOU WANT TO DO THE TEST BEFORE SEEING THE ANSWERS, DON"T READ FURTHER ;) (13 Replies)
Discussion started by: Neo
13 Replies
2. Shell Programming and Scripting
I am searching for a automation testing tool which I can use for most of the UNIX platforms (AIX, Linux, HP UX, Solaris). The installation process of the application in all platforms is almost same. Are you aware of any automation tool (like WinRunner for Windows) to solve my problem? (5 Replies)
Discussion started by: unmanju
5 Replies
3. UNIX for Dummies Questions & Answers
Hello, i have a script which checks if the user entered 8 numeric characters in the form of YYYYMMDD (birth date). If the user entered any non numeric characters, an error will be displayed:
# Check to see if the 8 characters are all numbers
# If not show error essage
# And prompt user... (4 Replies)
Discussion started by: netmaster
4 Replies
4. Shell Programming and Scripting
i have a unix script that gives me the sysdate from the database EDNAMID.WORLD.What i want my script to do the following
1) Establish a database connection
2) if database connection is successfull then echo the message "Connected"
3) put the o/p of the Sql query in a spool file
4) then... (3 Replies)
Discussion started by: ali560045
3 Replies
5. Shell Programming and Scripting
This is the code:
while test 1 -eq 1
do
read a
$a
if test $a = stop
then
break
fi
done
I read a command on every loop an execute it.
I check if the string equals the word stop to end the loop,but it say that I gave too many arguments to test.
For example echo hello.
Now the... (1 Reply)
Discussion started by: Max89
1 Replies
6. Shell Programming and Scripting
How to check weather a string is like test* or test* ot *test* in if condition (5 Replies)
Discussion started by: johnjerome
5 Replies
7. Shell Programming and Scripting
Hi
I have a test.dat file in UNIX which has a data.I am informatica developer i get data in those files.I need to add 50 spaces to those data in test.dat file.I am new to unix So can any one help how can i do that.
I have some 2088 rows in that test.dat file.
Can anyone help me please its... (11 Replies)
Discussion started by: karingulanagara
11 Replies
8. Shell Programming and Scripting
Hi Team,
-rwxr-xr-x 1 kmani00 system 9 Nov 08 03:29 tempfile.txt
-rwxrwxrwx 1 kmani00 devgrp 0 Nov 08 03:32 testfile.txt
by exec the following command, i did not get any output.
> test -s tempfile.txt
> a=`test -s tempfile.txt`
> echo $a
>
by exec the... (4 Replies)
Discussion started by: kmanivan82
4 Replies
9. Shell Programming and Scripting
Hello all,
working on Solaris 10 in ksh.
Basicly, in my function, i'm trying to test that all my unix cmd's are true (exit status 0) else you flag the rcControlRule to 1 without going into spagetti mode code testing every $? in a if statement.
The mdb is probably a little tricky cause it... (3 Replies)
Discussion started by: maverick72
3 Replies
10. UNIX for Beginners Questions & Answers
I want to xheck if a file exists that uses wildcards as only the partial filename is known using the test Command, and when it exists then output just the number of lines in the file... do not include the filename. Then this output, is it captured by the CommandOutput or the ReturnValue as I want... (2 Replies)
Discussion started by: dsinco
2 Replies
LEARN ABOUT DEBIAN
test::useallmodules
Test::UseAllModules(3pm) User Contributed Perl Documentation Test::UseAllModules(3pm)
NAME
Test::UseAllModules - do use_ok() for all the MANIFESTed modules
SYNOPSIS
# basic usage
use strict;
use Test::UseAllModules;
BEGIN { all_uses_ok(); }
# if you also want to test modules under t/lib
use strict;
use Test::UseAllModules under => qw(lib t/lib);
BEGIN { all_uses_ok(); }
# if you have modules that'll fail use_ok() for themselves
use strict;
use Test::UseAllModules;
BEGIN {
all_uses_ok except => qw(
Some::Dependent::Module
Another::Dependent::Module
^Yet::Another::Dependent::.* # you can use regex
)
}
DESCRIPTION
I'm sick of writing 00_load.t (or something like that) that'll do use_ok() for every module I write. I'm sicker of updating 00_load.t when
I add another file to the distro. This module reads MANIFEST to find modules to be tested and does use_ok() for each of them. Now all you
have to do is update MANIFEST. You don't have to modify the test any more (hopefully).
EXPORTED FUNCTION
all_uses_ok
Does Test::More's use_ok() for every module found in MANIFEST. If you have modules you don't want to test, give those modules or some regex
rules as the argument. The word 'except' is ignored as shown above.
As of 0.11, you can also test modules under arbitrary directories by providing a directory list at the loading time (the word 'under' is
ignored as shown above). Modules under the lib directory are always tested.
PROTECTED FUNCTION
_get_module_list
Returns module paths to test. This function will not be exported. If you want to use this (see below), you always need to call it by the
full qualified name.
NOTES
As of 0.03, this module calls BAIL_OUT of Test::More if any of the use_ok tests should fail. (Thus the following tests will be ignored.
Missing or unloadable modules cause a lot of errors of the same kind.)
As of 0.12, you can add extra tests before/after all_uses_ok() if you explicitly declare test plan like this.
use strict;
use warnings;
use Test::More;
use Test::UseAllModules;
use Test::NoWarnings;
plan tests => Test::UseAllModules::_get_module_list() + 1;
all_uses_ok();
# and extra nowarnings test
SEE ALSO
There're several modules like this on the CPAN now. Test::Compile and a bit confusing Test::LoadAllModules try to find modules to test by
traversing directories. I'm not a big fun of them as they tend to find temporary or unrelated modules as well, but they may be handier
especially if you're too lazy to update MANIFEST every time.
AUTHOR
Kenichi Ishigaki, <ishigaki@cpan.org>
COPYRIGHT AND LICENSE
Copyright (C) 2006 by Kenichi Ishigaki
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
perl v5.10.0 2009-05-27 Test::UseAllModules(3pm)