Most of the time when one needs to check when two values are different one could run:

  ok !t_cmp(...)

but the diagnostics is wrong, since received will be matching 'expected'

For example:

  ok !t_cmp $received, qr/message/

# testing : whatever
# expected: (?-xism:message)
# received: [...] [notice] [client 127.0.0.1] message must not appear!
not ok 32

so the verbose output is confusing.

so we probably need to introduce a new directive t_cmp_no() or something similar which will be run as:

  ok t_cmp_no $received, qr/message/

and log as:

# testing : whatever
# expected: ! (?-xism:message)
# received: [...] [notice] [client 127.0.0.1] message must not appear!
not ok 32

or something like that. internally it'd run !~, neq and != depending on the arguments.

Comments?

--
__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:[EMAIL PROTECTED] http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

Reply via email to