Skip Menu |

This queue is for tickets about the Test-Script-Run CPAN distribution.

Report information
The Basics
Id: 66832
Status: resolved
Priority: 0/
Queue: Test-Script-Run

People
Owner: Nobody in particular
Requestors: nomad [...] null.net
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: last_script_* functions don't work for "is_script_output()"
Date: Thu, 24 Mar 2011 12:40:24 +1300
To: bug-Test-Script-Run [...] rt.cpan.org
From: Mark Lawrence <nomad [...] null.net>
It is not clear from the documentation that the last_script_* functions only apply to the previous call to "run_script", and not also to other test functions such as "is_script_output" or "run_output_matches" etc. Either there is a bug in the documentation (that doesn't mention this restriction) or a bug in the code (that doesn't set the $last_* values where it should). It would be nice to be able to check the command return value when using "run_output_matches". -- Mark Lawrence
Hi Mark did you test? I believe last_script_* apply to all the command that run script, including run_script, is_script_output, run_output_matches, etc. this behavior is included in tests, so as long as tests pass for you, it should work. fyi, technically, is_script_output calls run_script internally, so it surely sets $last_script_* values. best wishes sunnavy On Wed Mar 23 19:40:48 2011, nomad@null.net wrote: Show quoted text
> It is not clear from the documentation that the last_script_* functions > only apply to the previous call to "run_script", and not also to other > test functions such as "is_script_output" or "run_output_matches" etc. > > Either there is a bug in the documentation (that doesn't mention this > restriction) or a bug in the code (that doesn't set the $last_* values > where it should). > > It would be nice to be able to check the command return value when > using "run_output_matches". >