DCIT / perl-CryptX

https://metacpan.org/pod/CryptX
Other
35 stars 23 forks source link

Many test failures under Strawberry Perl 5.40.0.1 #108

Closed shawnlaffan closed 2 months ago

shawnlaffan commented 2 months ago

Building with current HEAD commit (259e53ce9e41564a3e78107db94ddb825a88ede7) results in many test failures under Strawberry Perl 5.40.0.1.

Test log is below.

Many appear to be issues with CRLF line endings on Windows which read_rawfile does not correct for given it uses binmode.
https://github.com/DCIT/perl-CryptX/blob/259e53ce9e41564a3e78107db94ddb825a88ede7/lib/Crypt/Misc.pm#L159-L166

An example failure is https://github.com/DCIT/perl-CryptX/blob/259e53ce9e41564a3e78107db94ddb825a88ede7/t/pk_x25519.t#L129

Which results in:

t/pk_x25519.t ....................... 1/63
#   Failed test 'export_key_pem public'
#   at t/pk_x25519.t line 129.
#          got: '-----BEGIN PUBLIC KEY-----
# MCowBQYDK2VuAyEA6ngG9yGoVwUSyPbvtOjWIMSaUp5N9eqnfexkb7HofkE=
# -----END PUBLIC KEY-----
# '
#     expected: '-----BEGIN PUBLIC KEY-----
# MCowBQYDK2VuAyEA6ngG9yGoVwUSyPbvtOjWIMSaUp5N9eqnfexkb7HofkE=
# -----END PUBLIC KEY-----
# '

Full log is attached.

test_log.txt

karel-m commented 2 months ago

I guess that it is probably a CRLF related problem in your git client confuguration as CryptX-0.080_012 (wich is plus/minus the latest master of CryptX repo) install fines on strawberry perl 5.40

karel-m commented 2 months ago

Here is passing test on Strawberry perl 5.40 https://ci.appveyor.com/project/karel-m/perl-cryptx/builds/50559255/job/3xgfb0e6ox1i3ove

karel-m commented 2 months ago

A full list of all strawberry perl build results https://ci.appveyor.com/project/karel-m/perl-cryptx/builds/50559255

shawnlaffan commented 2 months ago

Thanks for releasing CryptX-0.081 to CPAN. It passes all tests on my machine also (unsurprisingly).

I guess that it is probably a CRLF related problem in your git client configuration as CryptX-0.080_012 (which is plus/minus the latest master of CryptX repo) install fines on strawberry perl 5.40

Git is set to use the default CRLF conversion on my system.

git config core.autocrlf
true

If development ever happens on Windows then this would be something to address, but it's otherwise not an issue currently unless one does cpanm https://github.com/DCIT/perl-CryptX.git, which I did initially to test the latest changes.