openssl / openssl

TLS/SSL and crypto library

Home Page:https://www.openssl.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Test failures

beldmit opened this issue · comments

I see many test failures looking like that.

15-test_dsa.t ........................... 
not ok 1 - require '../../test/recipes/tconversion.pl';
15-test_dsa.t ........................... 1/? ----------------------------------
    # No tests run!
not ok 4 - No tests run for subtest "dsa conversions using 'openssl dsa' -- private key"
# ------------------------------------------------------------------------------
#   Failed test 'No tests run for subtest "dsa conversions using 'openssl dsa' -- private key"'
#   at /home/dbelyavs/upstream/openssl/util/perl/OpenSSL/Test.pm line 1322.
Undefined subroutine &main::tconversion called at test/recipes/15-test_dsa.t line 29.
15-test_dsa.t ........................... Dubious, test returned 255 (wstat 65280, 0xff00)
Failed 5/7 subtests 

master branch, Fedora 39

Looks like require_ok(srctop_file("test", "recipes", "tconversion.pl")); is not enough to properly add the conversion procedure to a proper namespace.

$ perl -v

This is perl 5, version 38, subversion 2 (v5.38.2) built for x86_64-linux-thread-multi
(with 15 registered patches, see perl -V for more detail)

Copyright 1987-2023, Larry Wall

Perl may be copied only under the terms of either the Artistic License or the
GNU General Public License, which may be found in the Perl 5 source kit.

Complete documentation for Perl, including FAQ lists, should be found on
this system using "man perl" or "perldoc perl".  If you have access to the
Internet, point your browser at https://www.perl.org/, the Perl Home Page.

what versions of perl-Test-simple do you have installed? I don't see any updates to the package in the fedora release pages beyond the initial release version of perl-Test-Simple-1.302195-5, but my first thought would be that something in More.pm has changed thats causing tconversion.pl to fail somehow (though that seems unlikely)

Another thought, did tconversion.pl somehow get removed in your openssl source tree? From the above, it looks to me like the execution of require '../../test/recipes/tconverstion.pl' is what failed while calling require_ok, IIRC the two primary reasons a require directive fails are:
a) forgetting to have a 1; at the end of the file
b) the file not being where we said it was

$ yum info perl-Test-simple
Last metadata expiration check: 0:00:10 ago on Thu 06 Jun 2024 12:28:06 PM CEST.
Installed Packages
Name         : perl-Test-Simple
Epoch        : 3
Version      : 1.302195
Release      : 5.fc39
Architecture : noarch
Size         : 1.3 M
Source       : perl-Test-Simple-1.302195-5.fc39.src.rpm
Repository   : @System
From repo    : fedora
Summary      : Basic utilities for writing tests
URL          : https://metacpan.org/release/Test-Simple
License      : (GPL-1.0-or-later OR Artistic-1.0-Perl) AND CC0-1.0 AND LicenseRef-Fedora-Public-Domain
Description  : This package provides the bulk of the core testing facilities. For more
             : information, see perldoc for Test::Simple, Test::More, etc.
             : 
             : This package is the CPAN component of the dual-lifed core package Test-Simple.

Time::Piece is missing

not ok 1 - require '../../test/recipes/tconversion.pl';

#   Failed test 'require '../../test/recipes/tconversion.pl';'
#   at test/recipes/15-test_dsa.t line 22.
#     Tried to require ''../../test/recipes/tconversion.pl''.
#     Error:  Can't locate Time/Piece.pm in @INC (you may need to install the Time::Piece module) (@INC entries checked: /home/dbelyavs/upstream/openssl/Configurations . /home/dbelyavs/upstream/openssl/util/perl /home/dbelyavs/perl5/lib/perl5 /usr/local/lib64/perl5/5.38 /usr/local/share/perl5/5.38 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 /home/dbelyavs/upstream/openssl/external/perl/Text-Template-1.56/lib) at ../../test/recipes/tconversion.pl line 16.
# BEGIN failed--compilation aborted at ../../test/recipes/tconversion.pl line 16.
# Compilation failed in require at (eval 31) line 2.

Looks like it's a recently added dependency and it is not mentioned anywhere

Raised a discussion #24574, closing this