Re: Is this bit of scrip a reasonable way to test something

2022-01-02 Thread Vlado Keselj
It looks good to me. On Sun, 2 Jan 2022, hput via beginners wrote: > I was just coding in in ksh93 for simple script but tangled up with > way matching and regex work in ksh93. > > Finally trashed it turned to perl. > > Just have familiarity with one way of test in shell s

Re: Is this bit of scrip a reasonable way to test something

2022-01-02 Thread Hal Wigoda
> > Finally trashed it turned to perl. > > Just have familiarity with one way of test in shell script: > > Put it in an if clause like (in shell): > > > if [ cd somedir ];then >print "o

Is this bit of scrip a reasonable way to test something

2022-01-02 Thread hput via beginners
I was just coding in in ksh93 for simple script but tangled up with way matching and regex work in ksh93. Finally trashed it turned to perl. Just have familiarity with one way of test in shell script: Put it in an if clause like (in shell): if [ cd somedir ];then print "ok permis

Re: perl-5.32.0 - Failed test ''S' is set in PERL_UNICODE, or in -C, honor it, utf8 should be on'

2020-09-29 Thread Chas. Owens
y have the least amount of breakage on your system. On Mon, Sep 28, 2020 at 12:25 AM Robbi Nespu wrote: > Hello everyone, I am new with perl. > > My test server are using SLES11SP4 and it already EOL. > The latest openssl I can get from official repos it too old > > > $ openssl

Re: perl-5.32.0 - Failed test ''S' is set in PERL_UNICODE, or in -C, honor it, utf8 should be on'

2020-09-29 Thread Mike
a bad option. So we are saying that Perl v5.32.0 would not install on your machine.  Maybe I should stick with my Perl v5.30.0 Mike On 9/27/20 11:25 PM, Robbi Nespu wrote: Hello everyone, I am new with perl. My test server are using SLES11SP4 and it already EOL. The latest openssl I can get

perl-5.32.0 - Failed test ''S' is set in PERL_UNICODE, or in -C, honor it, utf8 should be on'

2020-09-27 Thread Robbi Nespu
Hello everyone, I am new with perl. My test server are using SLES11SP4 and it already EOL. The latest openssl I can get from official repos it too old $ openssl version OpenSSL 0.9.8j-fips 07 Jan 2009 I plan to update with newer openssl # cd /usr/local/src/openssl-1.1.1h # ./config Wl

Re: How to test for existence of file with non-ascii characters

2018-12-26 Thread Uri Guttman
On 12/26/18 7:31 AM, Mike Martin wrote: Any ideas how to test for the existance of a file, when the file name contains extended ascii characters For example if the file contains emdash (U-2014) file -e always returns false -e should not be looking at the filename directly. it checks if

Re: How to test for existence of file with non-ascii characters

2018-12-26 Thread Jesús Ruiz
I created a file whose name is just an emdash in bash with $ printf '\xe2\x80\x94' and this seems to work here (linux): my $fname = "\xe2\x80\x94"; if (-e "$fname") { print "exists\n" } On 2018-12-26 12:31:24, Mike Martin wrote: > Any ideas ho

How to test for existence of file with non-ascii characters

2018-12-26 Thread Mike Martin
Any ideas how to test for the existance of a file, when the file name contains extended ascii characters For example if the file contains emdash (U-2014) file -e always returns false thanks Mike

Re: Test

2018-11-04 Thread SATYABRATA KARAN
Hi Shravan, Please send the complex hash here, so we can tell you exactly how to substitute it. Regards, Satya

Re: Test

2018-11-04 Thread Andrew Solomon
Hi Shravan, If you go to this page and scroll down to the code snippet with Data::Rmap I think this may answer your question. https://www.linuxcareer.com/perl-as-a-career-option For further detail see https://metacpan.org/pod/Data::Rmap On Sun, Nov 4, 2018 at 4:24 AM Uri Guttman wrote: > On

Re: Test

2018-11-03 Thread Uri Guttman
On 10/27/18 6:27 AM, Shravan Uppin wrote: Hi do anyone know how to substitute for string in complex hashes i am not sure what you mean with that question. a string substition (the s/// op) can be done on any scalar. if you can access the scalar in a complex hash, you can do an s/// on it. o

Re: Test

2018-11-03 Thread Shravan Uppin
Hi do anyone know how to substitute for string in complex hashes Thank you Shravano On Tue, 23 Oct 2018, 19:33 Shravan Uppin, wrote: > Thank You > shravankumar >

TEST-Please Ignore

2014-03-08 Thread Alek Trishan
I posted to perl.beginners and since it hasn't shown up here, I thought I had better see if everything was OK with my connection to the mailing list. My apologies. -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.per

Re: time based test

2014-02-20 Thread shawn wilson
Thanks Also, for completeness, in that doc is also stated Time::Warp and someone also pointed me to Time::Mock and Test::TimeMock. The later seems to have the best interface for my needs, so I'll go with that. On Sat, Feb 15, 2014 at 6:05 AM, David Precious wrote: > On Fri, 14 Feb 2014

Re: time based test

2014-02-15 Thread David Precious
On Fri, 14 Feb 2014 16:21:52 -0500 shawn wilson wrote: > What I want is to be able to make a program /think/ that it's like a > week in the future without messing with the system time at all. So > something that overrides gmtime and localtime and the like with some > starting point would be aweso

Re: time based test

2014-02-14 Thread shawn wilson
hich part of the program do > you want to fool? You mean, you want > print scalar localtime(), "\n"; > > to print > Fri Feb 21 16:21:11 2014 > Yes, and works the same with Date::Time etc. So basically, I have a long running process and it flushes and reports on

time based test

2014-02-14 Thread shawn wilson
What I want is to be able to make a program /think/ that it's like a week in the future without messing with the system time at all. So something that overrides gmtime and localtime and the like with some starting point would be awesome. Anything like that? -- To unsubscribe, e-mail: beginners-un

Re: Test::More is_deeply failed data

2014-02-11 Thread Paul Johnson
($bar);' which just > doesn't seem like the right thing to do to figure out why a test is > failing? Perhaps you are looking for Test::Differences ? https://metacpan.org/pod/Test::Differences -- Paul Johnson - p...@pjcj.net http://www.pjcj.net -- To unsubscribe, e-mail: beginne

Re: Test::More is_deeply failed data

2014-02-11 Thread shawn wilson
Test::Differences looks like what I want. Also he documents gracefully falling back to is_deeply. I see no issue requiring it but the alternative is cool. On Feb 11, 2014 2:02 PM, "Shlomi Fish" wrote: > Hi Shawn, > > On Tue, 11 Feb 2014 13:17:15 -0500 > shawn wilson wrote

Re: Test::More is_deeply failed data

2014-02-11 Thread Shlomi Fish
umper($bar);' which just > doesn't seem like the right thing to do to figure out why a test is > failing? > Perhaps you want to use eq_or_diff() from https://metacpan.org/pod/Test::Differences , which does that. It's not a core module but is much better, and eq_or_diff() is

Re: Test::More is_deeply failed data

2014-02-11 Thread John SJ Anderson
On Tue, Feb 11, 2014 at 10:17 AM, shawn wilson wrote: > Is there a way to see the data difference when is_deeply fails? So, with this code: #! perl use Test::More; my $a = { foo => {bar => { baz => 'bargle' }}}; my $b = { foo => {baz => { bar => &#

Test::More is_deeply failed data

2014-02-11 Thread shawn wilson
Is there a way to see the data difference when is_deeply fails? proove -d doesn't give me the structure that fails. I end up 'print STDERR "one " . Dumper($foo); print STDERR 'two " . Dumper($bar);' which just doesn't seem like the right thing to do to f

Re: Test automation using perl or shell

2013-09-10 Thread Jim Gibson
On Sep 10, 2013, at 1:25 AM, Lalit Deshmukh wrote: > Hi, > > i have implemented 50 shell program to test. now i want to run all these > shell program one by one(in short test automation) (once first program > getting executed then next will start). please let me know how

Re: Test automation using perl or shell

2013-09-10 Thread Michael Rasmussen
On Tue, Sep 10, 2013 at 01:25:22AM -0700, Lalit Deshmukh wrote: > i have implemented 50 shell program to test. now i want to run all these > shell program one by one(in short test automation) (once first program > getting executed then next will start). please let me know how to do this?

Re: Test automation using perl or shell

2013-09-10 Thread Shekar
Hello Lalit, This question sounds more nearer to Shell scripting than Perl. No offence, you can do this in Perl too, but since underlaying test scripts are shell based (which you mentioned as 'i have implemented 50 shell program to test' ), i would suggest you to write a wrapper sh

Test automation using perl or shell

2013-09-10 Thread Lalit Deshmukh
Hi, i have implemented 50 shell program to test. now i want to run all these shell program one by one(in short test automation) (once first program getting executed then next will start). please let me know how to do this? in UNIX any utility or to run the same. any help will be really

Re: bool test return issues

2013-01-07 Thread David Precious
On Sat, 5 Jan 2013 09:01:26 -0700 Elim Qiu wrote: > perl shell is a good idear (I'm using ipython a lot. That's why I like > to try perl shell), but it really has problems. See attached > screenshot. Ah. Yeah, that's a different animal to Perl. This list can help you with problems with Perl, b

Re: bool test return issues

2013-01-07 Thread Brandon McCaig
Hello: On Sat, Jan 05, 2013 at 09:01:26AM -0700, Elim Qiu wrote: > perl shell is a good idear (I'm using ipython a lot. That's why I like > to try perl shell), but it really has problems. See attached > screenshot. I think you forgot to mention that you were using this psh. :) That or I missed it

Re: bool test return issues

2013-01-05 Thread Elim Qiu
perl shell is a good idear (I'm using ipython a lot. That's why I like to try perl shell), but it really has problems. See attached screenshot. On Sat, Jan 5, 2013 at 7:16 AM, David Precious wrote: > On Fri, 4 Jan 2013 15:43:41 -0700 > Elim Qiu wrote: > >> It's on snow leopard, perl version 5.10

Re: bool test return issues

2013-01-05 Thread David Precious
On Fri, 4 Jan 2013 15:43:41 -0700 Elim Qiu wrote: > It's on snow leopard, perl version 5.10.0 > > > > print 3 > 1, "\n"; > > prints 1 and ignored "\n" Includes the newline for me. If I had to hazard a guess, I'd say perhaps when you ran it you accidentally mistyped "." instead of "," (so yo

Re: bool test return issues

2013-01-04 Thread Rich Johnson
I'm getting both new lines to print. [code] use 5.10.0; print "1: "; print 3 > 1, "\n"; print "2: "; print 3 == 3, "\n"; [/code] [output] >perl booltest.pl 1: 1 2: 1 > [/output] Richard Johnson (708)253-8130 On Fri, Jan 4, 2013 at 5:43 PM, Elim Qiu wrote: > It's on snow leopard, perl versi

bool test return issues

2013-01-04 Thread Elim Qiu
It's on snow leopard, perl version 5.10.0 print 3 > 1, "\n"; prints 1 and ignored "\n" print 3 == 3, "\n"; prints 1 and "\n" There're some in consistency here. -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn

Re: Test Mail

2012-08-03 Thread Jeff Pang
congratulation, you have got it~ Fri, 3 Aug 2012 14:02:25 +0530 от Anitha Sreejith Victor : I want to subscribe to this perl forum thanks, Anitha -- Jeff Pang jeffp...@mail.ru

Re: Test Mail

2012-08-03 Thread Owen
> I want to subscribe to this perl forum Look at the message headers... List-Subscribe: -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Test Mail

2012-08-03 Thread Anitha Sreejith Victor
I want to subscribe to this perl forum thanks, Anitha

Re: Script to test connecting to Oracle DBs

2012-08-01 Thread Leo Susanto
$SQL = qq{ SELECT XXX}; my $sth0 = $dbh->prepare($SQL); print "SQL is prepared;\n"; $sth0->execute(); print "SQL is executed;\n"; $sth0->finish(); On Fri, Jul 27, 2012 at 6:45 PM, newbie01 perl wrote: > Hi all, > > I am looking for a Perl script or something si

RE: Script to test connecting to Oracle DBs

2012-08-01 Thread Martin Gainty
ulation, nous ne pouvons accepter aucune responsabilité pour le contenu fourni. > Date: Sat, 28 Jul 2012 13:45:18 +1200 > Subject: Script to test connecting to Oracle DBs > From: newbie01.p...@gmail.com > To: beginners@perl.org; dbi-us...@perl.org > > Hi all, > > I am lookin

Re: Script to test connecting to Oracle DBs

2012-07-27 Thread Rob Dixon
On 28/07/2012 02:45, newbie01 perl wrote: > Hi all, > > I am looking for a Perl script or something similar that I can use to test > connection from a client PC to several databases on a server. > > Does anyone know of any such script lying around somewhere :(- > &g

Script to test connecting to Oracle DBs

2012-07-27 Thread newbie01 perl
Hi all, I am looking for a Perl script or something similar that I can use to test connection from a client PC to several databases on a server. Does anyone know of any such script lying around somewhere :(- Currently, am testing connection from a client PC to an Oracle DB using Oracle&#

Re: how to resolve this Unparsable version '' for prerequisite Test::Strict at Makefile.PL line 563

2012-07-20 Thread Shlomi Fish
Hi Amit, On Fri, 20 Jul 2012 17:50:47 +0530 amit bondwal wrote: > Dear All, > > I am new to perl, I am facing a problem > while installing koha LMS software. When O run the Makefile.pl it shows > the below error: > Unparsable version '' for prerequisite Test::St

how to resolve this Unparsable version '' for prerequisite Test::Strict at Makefile.PL line 563

2012-07-20 Thread amit bondwal
Dear All, I am new to perl, I am facing a problem while installing koha LMS software. When O run the Makefile.pl it shows the below error: Unparsable version '' for prerequisite Test::Strict at Makefile.PL line 563 What is Unparsable version of Test::Strict? is it mean that I am u

Re: File test operator (race conditions)

2011-11-27 Thread Jim Gibson
The file exists or does not exist at the time the test is made, and the printed output is true for that time (and that time only). A race condition would exist if the program assumed that the file's existence did not change after it was tested and acted upon that assumption uncondit

Re: File test operator (race conditions)

2011-11-27 Thread timothy adigun
> > > From: Owen > > > > There is no race condition. > > > > And that code demo is correct > Actually, there is in a multitasking environment. Please, check subtitle "File Locking" in perldoc perlopentut. masayoshi wrote: > Before calling print method, the file might be deleted by another p

Re: File test operator (race conditions)

2011-11-27 Thread masayoshi
- Original Message - > From: Owen > > There is no race condition. > > And that code demo is correct > Before calling print method, the file might be deleted by another process So I reckoned when "File exists" appeared, the file might be deleted. >_>   --- masayoshi & Ayumi Kinoshita

Re: File test operator (race conditions)

2011-11-27 Thread Owen
> Hi,I am masayoshi. > I read the following article. > > http://perltraining.com.au/tips/2005-11-24.html > > > A lot of website use the following script to explain file test > operators, > But I reckon I should not write it for race conditions. > Is this right? >

File test operator (race conditions)

2011-11-27 Thread masayoshi
Hi,I am masayoshi. I read the following article. http://perltraining.com.au/tips/2005-11-24.html A lot of website use the following script to explain file test operators, But I reckon I should not write it for race conditions. Is this right? Thanks in advance. #!/usr/bin/perl use strict; use

Re: Perl 5.12.1 manual install - make test problem.

2011-10-20 Thread Brian Fraser
2011/10/20 Rafał Radecki > Hi all. > I am installing locally perl using howto > http://www.mail-archive.com/padre-dev@perlide.org/msg00363.html . > When I make make test I returns message about an error in > porting/checkcase.t and a hint to: > export LD_LIBRARY_PATH=`pwd`;c

Perl 5.12.1 manual install - make test problem.

2011-10-20 Thread Rafał Radecki
Hi all. I am installing locally perl using howto http://www.mail-archive.com/padre-dev@perlide.org/msg00363.html . When I make make test I returns message about an error in porting/checkcase.t and a hint to: export LD_LIBRARY_PATH=`pwd`;cd t;./perl harness Then I get: porting/checkcase.t (Wstat: 0

Re: File test failed!

2011-09-16 Thread Magnus Woldrich
On 2011-09-16 17:53, y...@eisoo.com wrote: I want to test if a file exists or it is a link or not You test for a regular file with -f. You test for existance with -e. You test for symbolic links with -l. See perldoc -f -x for more information. -- │ Magnus Woldrich │ m...@japh.se │ http

Re: File test failed!

2011-09-16 Thread Shlomi Fish
Hi YYQ, On Fri, 16 Sep 2011 17:53:25 +0800 "y...@eisoo.com" wrote: > Hi, All: > > I want to test if a file exists or it is a link or not, the code is: > #!/usr/bin/perl -w > > use strict; > use File::Basename; > use File::stat; > use Fcntl ':m

File test failed!

2011-09-16 Thread y...@eisoo.com
Hi, All: I want to test if a file exists or it is a link or not, the code is: #!/usr/bin/perl -w use strict; use File::Basename; use File::stat; use Fcntl ':mode'; my $elfobj = $ARGV[0]; sub strtrim () { #. } sub copyfile () { #. } my @deps = `ldd $elfobj`;

Re: unit test case for this perl code

2011-09-03 Thread flebber
On Sep 2, 4:46 am, ratul...@yahoo.co.in (anirban adhikary) wrote: > Hi I have write the following code and Now I have been asked to write a unit > test case for this code. But neither I have  any idea how to write a unit > test case nor I have ever experience with it. So in this case I

Re: unit test case for this perl code

2011-09-03 Thread Peter Scott
On Fri, 02 Sep 2011 14:16:30 +0530, anirban adhikary wrote: > Hi I have write the following code and Now I have been asked to write a > unit test case for this code. But neither I have  any idea how to write > a unit test case nor I have ever experience with it. So in this case I > am

unit test case for this perl code

2011-09-02 Thread anirban adhikary
Hi I have write the following code and Now I have been asked to write a unit test case for this code. But neither I have  any idea how to write a unit test case nor I have ever experience with it. So in this case I am asking your help. #!/usr/bin/perl ### ## The program is called by main.pl

Subscription Test

2011-05-31 Thread Elavazhagan Elayaperumal
Subscription Test =-=-= Notice: The information contained in this e-mail message and/or attachments to it may contain confidential or privileged information. If you are not the intended recipient, any dissemination, use, review, distribution, printing or copying of the

Re: how to test all files in array exist in the tar using Archive::Tar

2011-04-26 Thread Agnello George
r,  9 ); > > > Have you read the Archive::Tar documentation? Either 'perldoc Archive::Tar' > on a command-line or here: > > <http://search.cpan.org/~bingos/Archive-Tar-1.76/lib/Archive/Tar.pm> > > Have you tried the contains_file($filename) method listed there? Be

Re: how to test all files in array exist in the tar using Archive::Tar

2011-04-26 Thread Jim Gibson
e/Tar.pm> Have you tried the contains_file($filename) method listed there? Be sure to include the full path if you do. i also need to test the tar file in , i cant find a option in Archive::Tar , some thing similar to tar -tvf sometar.tgz Have you tried the list_files method of Archive::Tar? -- T

how to test all files in array exist in the tar using Archive::Tar

2011-04-26 Thread Agnello George
uded); $tar->write( $fultar, 9 ); i also need to test the tar file in , i cant find a option in Archive::Tar , some thing similar to tar -tvf sometar.tgz Can some one help me with this . thanks -- Regards Agnello D'souza -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For a

Re: How to test for 2 words from a list in a form field?

2011-04-10 Thread shawn wilson
On Apr 10, 2011 5:54 AM, "John W. Krahn" wrote: > > shawn wilson wrote: >> >> >> heh, i've got to learn to test my code before posting - i'm ending >> looking like an idiot :) >> *sigh* this is what i wanted to say: >> >> >

Re: How to test for 2 words from a list in a form field?

2011-04-10 Thread John W. Krahn
shawn wilson wrote: heh, i've got to learn to test my code before posting - i'm ending looking like an idiot :) *sigh* this is what i wanted to say: #!/usr/bin/perl use warnings; use strict; my $fields1 = "a little sentense with one and it will match with two\n"; my

Re: How to test for 2 words from a list in a form field?

2011-04-09 Thread shawn wilson
ord (@words) { >>  $count++ if( $word ~~ @match ); >> } >> print "cool\n" if $count>= 2; >> >> > > How does this code work?  For one thing, you have @match = [ ]; which is > assigning an array reference to an array?  Maybe I'm not understanding

Re: How to test for 2 words from a list in a form field?

2011-04-09 Thread Brian F. Yulga
Brian F. Yulga wrote: my @mail_types = qw( avenue road box lane ); my @words = split /\s/, $fields; my $count = grep { my $found; foreach my $street ( @mail_types ) { if ( /\b$street\b/i ) { $found++; last; } } $found; } @words; print qq(fo

Re: How to test for 2 words from a list in a form field?

2011-04-09 Thread Brian F. Yulga
shawn wilson wrote: On Sat, Apr 9, 2011 at 3:29 PM, wrote: my $address_count = () = $str =~ /box|street|avenue|lane|apo/ig; what does print $var = () = $str =~ /regex/; do? particularly the '= () ='? According to "Effective Perl Programming (2nd Ed.)", Item 9 (Know the dif

Re: How to test for 2 words from a list in a form field?

2011-04-09 Thread John W. Krahn
shawn wilson wrote: On Sat, Apr 9, 2011 at 3:29 PM, wrote: It is detecting but not testing if any particular 2 words are in a text field and I think that's what you explained you were testing for. Sorry if my first post was misleading. Those were just some examples. I'm looking o

Re: How to test for 2 words from a list in a form field?

2011-04-09 Thread shawn wilson
o/i, qr/etc/i ]; my @words = split /[^\s]+/, $fields; my $count = 0; foreach my $word (@words) { $count++ if( $word ~~ @match ); } print "cool\n" if $count >= 2; there might be a better way to do this. i generally use this if i want to test for any regex in a line as it just matches the first

Re: How to test for 2 words from a list in a form field?

2011-04-09 Thread sono-io
Hi Chris, > It is detecting but not testing if any particular 2 words are in a > text field and I think that's what you explained you were testing for. Sorry if my first post was misleading. Those were just some examples. I'm looking only for an occurrence of _any_ two words in that li

Re: How to test for 2 words from a list in a form field?

2011-04-08 Thread charley
On Apr 8, 10:59 pm, char...@pulsenet.com wrote: > On Apr 8, 9:06 pm, sono...@fannullone.us wrote: > > >         Three hours later, I finally had a brainstorm, and came up with the > > idea to count the number of occurrences of the words I'm looking for.   > > Here's what I came up with: > > > my $

Re: How to test for 2 words from a list in a form field?

2011-04-08 Thread charley
On Apr 8, 9:06 pm, sono...@fannullone.us wrote: >         Three hours later, I finally had a brainstorm, and came up with the > idea to count the number of occurrences of the words I'm looking for.  Here's > what I came up with: > > my $str = "PO Box 6545 / 3546 Termbo Street"; > my $address_coun

Re: How to test for 2 words from a list in a form field?

2011-04-08 Thread charley
On Apr 8, 9:06 pm, sono...@fannullone.us wrote: >         Three hours later, I finally had a brainstorm, and came up with the > idea to count the number of occurrences of the words I'm looking for.  Here's > what I came up with: > > my $str = "PO Box 6545 / 3546 Termbo Street"; > my $address_coun

Re: How to test for 2 words from a list in a form field?

2011-04-08 Thread sono-io
Three hours later, I finally had a brainstorm, and came up with the idea to count the number of occurrences of the words I'm looking for. Here's what I came up with: my $str = "PO Box 6545 / 3546 Termbo Street"; my $address_count = 0; $address_count++ while ($str =~ /box|street|avenue|

How to test for 2 words from a list in a form field?

2011-04-08 Thread sono-io
Hello, I'm wanting to test for the presence of two or more words, from a short list of words, in an address input field in a Perl shopping cart, i.e. both 'box' and 'street', or both 'apo' and 'avenue', etc. and pop up a message. I've

Re: -d test stops working

2011-02-18 Thread Shawn H Corey
On 11-02-17 08:34 PM, Téssio Fechine wrote: I just found the bug.. If you're traversing directories, you should use File::Find. It's a standard module that is installed with Perl. See `perldoc File::Find` for details. Also, to get a list of the standard modules and pragmatics: perldoc per

Re: -d test stops working

2011-02-18 Thread Téssio Fechine
"..: $!\n"; } # main program die "$0: missing operand\n" if @ARGV < 1; foreach (@ARGV) { list_dir $_; } -- 'chdir ".." or die "..: $!\n"' is the bug fix.. :) > Assunto: -d test stops working > Para: beginners@perl.org > Data: Q

-d test stops working

2011-02-18 Thread Téssio Fechine
[0]"; } list_dir $ARGV[0]; -- But it appears to break in the -d test of the subdirectory 'linux': root@pacman:/home# /bin/ls -l tessio2/Books total 10744 -rw-r--r-- 1 root root 2412061 2011-02-16 21:14 802.1Q-2005.pdf -rw-r--r-- 1 root root 273110 2011-02-16 21:14 Artigo_SNMP.pd

install module ExtUtils-ParseXS on solaris test fail

2010-09-14 Thread 小强
Hello All, I want to install the module ExtUtils-ParseXS(that is a dependancy module for Log-Dispatch) on solaris 10, I would like to install the module by gcc instead of Sun cc. First I launched "perlgcc Makefile.PL", Then "make" and "make test". Since the module E

Re: How to test Output when using IPC::Open3

2010-08-31 Thread C.DeRykus
On Aug 29, 10:46 pm, ole...@gmail.com (marcos rebelo) wrote: > We are out of contest in here. > > I know how to run open3, but I don't know how to test it. Repeating > Hm, I just wanted to warn you that Open3 may easily require more paranoia than you've shown... your samp

Re: How to test Output when using IPC::Open3

2010-08-29 Thread marcos rebelo
We are out of contest in here. I know how to run open3, but I don't know how to test it. Repeating use strict; use warnings; use IPC::Open3; use IO::Handle; use Test::More; use Test::Trap; sub shell_run { my ($stdin, $stdout, $stderr) = map {IO::Handle->new} (0..2); pri

Re: How to test Output when using IPC::Open3

2010-08-29 Thread C.DeRykus
On Aug 28, 10:42 pm, ole...@gmail.com (marcos rebelo) wrote: > the idea is to process the STDOUT ad the STDERR. > > open don't do it > I was afraid you'd say that... open3 is very liable to deadlock since you're trying to read from both stderr and stdout. You'll very likely want to use IO::Selec

Re: How to test Output when using IPC::Open3

2010-08-28 Thread marcos rebelo
the idea is to process the STDOUT ad the STDERR. open don't do it Best Regards Marcos Rebelo On Sun, Aug 29, 2010 at 6:08 AM, John W. Krahn wrote: > C.DeRykus wrote: >> >> Since you mention simplifying the code, do you actually >> need IPC::Open3 ?  In your sample code, you're only >> reading p

Re: How to test Output when using IPC::Open3

2010-08-28 Thread John W. Krahn
C.DeRykus wrote: Since you mention simplifying the code, do you actually need IPC::Open3 ? In your sample code, you're only reading process output. If you don't need IPC::Open3 complexity, you could just use magic open to read output : sub shell_run { print ""; my $pid = open( m

Re: How to test Output when using IPC::Open3

2010-08-28 Thread C.DeRykus
On Aug 28, 12:45 am, ole...@gmail.com (marcos rebelo) wrote: > I'm having a more or less complicated code, that was simplified to this. > > use strict; > use warnings; > use IPC::Open3; > use IO::Handle; > use Test::More; > use Test::Trap; > > sub shell_run {

How to test Output when using IPC::Open3

2010-08-28 Thread marcos rebelo
I'm having a more or less complicated code, that was simplified to this. use strict; use warnings; use IPC::Open3; use IO::Handle; use Test::More; use Test::Trap; sub shell_run { my ($stdin, $stdout, $stderr) = map {IO::Handle->new} (0..2); print ""; ope

Re: test contents of variable using alarm()

2010-08-25 Thread Chas. Owens
On Wed, Aug 25, 2010 at 02:39, Kammen van, Marco, Springer SBM NL wrote: > Original Message- > From: Chas. Owens [mailto:chas.ow...@gmail.com] > Sent: Friday, August 20, 2010 4:07 PM > To: Kammen van, Marco, Springer SBM NL > Cc: beginners@perl.org > Subject: Re: test co

RE: test contents of variable using alarm()

2010-08-24 Thread Kammen van, Marco, Springer SBM NL
Original Message- From: Chas. Owens [mailto:chas.ow...@gmail.com] Sent: Friday, August 20, 2010 4:07 PM To: Kammen van, Marco, Springer SBM NL Cc: beginners@perl.org Subject: Re: test contents of variable using alarm() On Fri, Aug 20, 2010 at 04:34, Kammen van, Marco, Springer SBM NL

Re: test contents of variable using alarm()

2010-08-20 Thread Chas. Owens
On Fri, Aug 20, 2010 at 04:34, Kammen van, Marco, Springer SBM NL wrote: > Hi All, > > I want to use timers to check if certain variables are set and if not > send some data back to a client... > > Been searching for this a while now, but all I can find on alarm are > examples on timing out comman

test contents of variable using alarm()

2010-08-20 Thread Kammen van, Marco, Springer SBM NL
Hi All, I want to use timers to check if certain variables are set and if not send some data back to a client... Been searching for this a while now, but all I can find on alarm are examples on timing out commands So something like: sub timeout { $timeout = 5; eval { l

test

2010-06-25 Thread Alexandru Cardaniuc
please ignore -- "We are usually convinced more easily by reasons we have found ourselves than by those which have occurred to others." - Blaise Pascal (1623-1662) -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.

Re: No paths in Test-Harness-3.21.tar

2010-06-22 Thread Uri Guttman
> "BM" == Bob McConnell writes: BM> You do know that Sherlock Holmes was a fictional character, don't you? BM> If any of my diagnostics were that superficial, I would never have BM> lasted 30 years in this profession, nor any other. A much better BM> guideline would be one Bob Pease (

RE: No paths in Test-Harness-3.21.tar

2010-06-22 Thread Bob McConnell
From: Uri Guttman >> "BM" == Bob McConnell writes: > > BM> From: Uri Guttman > > >> that implicates the tar.exe in your box as the guilty party. put > >> the blame on camelbox for not handling some variation in tar > >> headers that all other tar utils and modules can handle. report >

Re: No paths in Test-Harness-3.21.tar

2010-06-22 Thread Uri Guttman
> "BM" == Bob McConnell writes: BM> From: Uri Guttman >> that implicates the tar.exe in your box as the guilty party. put >> the blame on camelbox for not handling some variation in tar >> headers that all other tar utils and modules can handle. report >> this as a big bug BM> to

RE: No paths in Test-Harness-3.21.tar

2010-06-22 Thread Bob McConnell
From: Uri Guttman >> "BM" == Bob McConnell writes: > > BM> To remove the tar binary from Config.pm: > BM> 1) Open C:\camelbox\lib\CPAN\Config.pm in an editor that understands > BM> Unix files (NOT notepad.exe; wordpad will work for this) > BM> 2) Find the line that says 'tar' => q[C:\\ca

Re: No paths in Test-Harness-3.21.tar

2010-06-22 Thread Uri Guttman
> "BM" == Bob McConnell writes: BM> To remove the tar binary from Config.pm: BM> 1) Open C:\camelbox\lib\CPAN\Config.pm in an editor that understands BM> Unix files (NOT notepad.exe; wordpad will work for this) BM> 2) Find the line that says 'tar' => q[C:\\camelbox\\bin\\tar.EXE] and

RE: No paths in Test-Harness-3.21.tar

2010-06-22 Thread Bob McConnell
opers did give me a workaround that seems to >> get me past this issue for now. > > Please post the workaround for the archives, if you wouldn't mind. The workaround for this is to remove the tar binary from CPAN's Config.pm file. I just confirmed Test::Harness unpacks aft

Re: No paths in Test-Harness-3.21.tar

2010-06-21 Thread Steve Bertrand
On 2010.06.21 18:22, Bob McConnell wrote: > After a little more digging, and trying your suggestion to try from > Linux, I have determined that the directory information in the new tar > files is being put into the prefix field of the header. But apparently > the older versions of tar (and WinZIP)

RE: No paths in Test-Harness-3.21.tar

2010-06-21 Thread Bob McConnell
re padded differently, but I don't know what effect this would >> BM> have. >> >> the absolute vs relative paths may mean something. maybe the author >> switched tars when they switched source control? tar is best with >> relative paths so you can untar it anywhere.

Re: No paths in Test-Harness-3.21.tar

2010-06-21 Thread Uri Guttman
> "BM" == Bob McConnell writes: BM> I have posted the question on the Camelbox forum, but have not yet BM> received any response. I don't know where to take CPAN problems, BM> since I have never had any before. After reading what I can find BM> of the tar format, I think the utility u

RE: No paths in Test-Harness-3.21.tar

2010-06-21 Thread Bob McConnell
ld > BM> have. > > the absolute vs relative paths may mean something. maybe the author > switched tars when they switched source control? tar is best with > relative paths so you can untar it anywhere. I should have said full paths, instead of relative. The difference is &#x

Re: No paths in Test-Harness-3.21.tar

2010-06-21 Thread Uri Guttman
> "BM" == Bob McConnell writes: BM> Looking at the two tar files with a binary viewer after uncompressing BM> them through gzip, I see several differences, but other than the BM> obvious, I don't know which are significant. The obvious difference is BM> that the tar file headers for 3

RE: No paths in Test-Harness-3.21.tar

2010-06-21 Thread Bob McConnell
From: Uri Guttman >> "BM" == Bob McConnell writes: > BM> Yes, that was all one line. Lookout doesn't give me any options to > BM> prevent it from wrapping. Microsoft _always_ believe they know what's > BM> best for you. > > so don't use outhouse for mail. simple! Not my choice. It is de

  1   2   3   4   5   6   7   >