gnustavo / Git-Hooks

Framework for implementing Git (and Gerrit) hooks
http://search.cpan.org/dist/Git-Hooks/
41 stars 17 forks source link

t/02-check-file.t fails (with newer git?) #56

Closed eserte closed 6 years ago

eserte commented 6 years ago

On my freebsd 11 smokers the test suite fails:

# git version 2.18.0
fatal: No such section! at t/02-check-file.t line 156.
# Looks like your test exited with 128 just after 14.
t/02-check-file.t ............ 
Dubious, test returned 128 (wstat 32768, 0x8000)
Failed 22/36 subtests 

Statistical analysis suggests that this is failing for newer git versions (2.18.0 and 2.19.0):

****************************************************************
Regression 'qr:git version (\S+)'
****************************************************************
Name                   Theta          StdErr     T-stat
[0='const']           1.0000          0.0000    179915762460269088.00
[1='eq_1.7.1']       -0.0000          0.0000      -0.07
[2='eq_1.7.10.4']             0.0000          0.0000       0.97
[3='eq_2.1.4']       -0.0000          0.0000      -0.12
[4='eq_2.11.0']      -0.0000          0.0000      -0.22
[5='eq_2.17.0']      -0.0000          0.0000      -2.99
[6='eq_2.17.1']       0.0000          0.0000       9.57
[7='eq_2.18.0']      -1.0000          0.0000    -87271963804379584.00
[8='eq_2.19.0']      -1.0000          0.0000    -77905810415919856.00
[9='eq_2.7.4']       -0.0000          0.0000      -1.06

R^2= 1.000, N= 94, K= 10
****************************************************************
eserte commented 6 years ago

I was able to reproduce the problem also in a debian:buster system (where also a newer git is installed (2.19.0)). The Dockerfile:

# docker build -t perl-test . && docker run perl-test
FROM debian:buster
RUN apt-get -y update
RUN apt-get -y install perl-modules
RUN apt-get -y install make
RUN apt-get -y install git

# Speed up dependency installation
RUN apt-get -y install libemail-sender-perl libemail-simple-perl libgit-repository-perl libgit-repository-plugin-log-perl libio-interactive-perl liblist-moreutils-perl libpath-tiny-perl libtext-glob-perl liburi-perl libmodule-build-perl

CMD cpan -t GNUSTAVO/Git-Hooks-2.9.6.tar.gz
# test case for https://github.com/gnustavo/Git-Hooks/issues/56
gnustavo commented 6 years ago

Thanks!

I just released version 2.9.7 which should fix this problem.