You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Some of the tests in dist/Safe/t are conditional. Most of them just check whether $Config{extensions} lists Opcode as available, which makes sense since Safe uses Opcode. But a few of them add some extra conditions that make no sense to me.
The worst offender is probably dist/Safe/t/safe3.t:
On VMS, always run this test, regardless of whether Opcode/POSIX are available.
On non-VMS systems, run this test if either Opcode or POSIX are available.
Only skip this test if we're not on VMS and both Opcode and POSIX are unavailable.
I would've expected all those && to be ||, i.e. to skip the test if we're on VMS, or Opcode is unavailable, or POSIX is unavailable, because the following code then unconditionally loads POSIX and Safe (which pulls in Opcode).
The full list of test files with similar code is:
dist/Safe/t/safe1.t
dist/Safe/t/safe2.t
dist/Safe/t/safe3.t
dist/Safe/t/safeops.t
dist/Safe/t/safesort.t
dist/Safe/t/safeutf8.t
dist/Safe/t/safewrap.t
Steps to Reproduce
grep VMS dist/Safe/t/*
Expected behavior
The skip conditions should logically use ||, not &&.
The text was updated successfully, but these errors were encountered:
I had a look over the history of some of the tests, my first suspicion was that VMS wasn't populating extensions at some point, but I didn't find any indication of that in the history of the VMS configure.com.
Maybe @craigberry has some idea for why the VMS check is done.
Module: Safe
Description
Some of the tests in
dist/Safe/t
are conditional. Most of them just check whether$Config{extensions}
listsOpcode
as available, which makes sense sinceSafe
usesOpcode
. But a few of them add some extra conditions that make no sense to me.The worst offender is probably
dist/Safe/t/safe3.t
:Essentially, what this is saying is:
Opcode
/POSIX
are available.Opcode
orPOSIX
are available.Opcode
andPOSIX
are unavailable.I would've expected all those
&&
to be||
, i.e. to skip the test if we're on VMS, orOpcode
is unavailable, orPOSIX
is unavailable, because the following code then unconditionally loadsPOSIX
andSafe
(which pulls inOpcode
).The full list of test files with similar code is:
dist/Safe/t/safe1.t
dist/Safe/t/safe2.t
dist/Safe/t/safe3.t
dist/Safe/t/safeops.t
dist/Safe/t/safesort.t
dist/Safe/t/safeutf8.t
dist/Safe/t/safewrap.t
Steps to Reproduce
grep VMS dist/Safe/t/*
Expected behavior
The skip conditions should logically use
||
, not&&
.The text was updated successfully, but these errors were encountered: