Subject: | Failed test 'Runtime error' at t/08-errors.t line 26 (on multibyte language system) |
Hello.
I encountered an failure when running tests of Statistics-R-0.34 on perl-5.22.0.
Maybe, a test 'Runtime error' of t/08-errors.t is depend to language settings.
Following is build.log
######
$ cpanm Statistics::R
--> Working on Statistics::R
Fetching http://www.cpan.org/authors/id/F/FA/FANGLY/Statistics-R-0.34.tar.gz ... OK
Configuring Statistics-R-0.34 ... OK
Building and testing Statistics-R-0.34 ... FAIL
! Installing Statistics::R failed. See /Users/azuma.satoshi/.cpanm/work/1519699952.55772/build.log for details. Retry with --force to force install it.
sazuma-mbp:kh_coder azuma.satoshi$ cat /Users/azuma.satoshi/.cpanm/work/1519699952.55772/build.log
cpanm (App::cpanminus) 1.7040 on perl 5.022000 built for darwin-2level
Work directory is /Users/azuma.satoshi/.cpanm/work/1519699952.55772
You have make /usr/bin/make
You have LWP 6.13
You have /usr/bin/tar: bsdtar 2.8.3 - libarchive 2.8.3
You have /usr/bin/unzip
Searching Statistics::R () on cpanmetadb ...
--> Working on Statistics::R
Fetching http://www.cpan.org/authors/id/F/FA/FANGLY/Statistics-R-0.34.tar.gz
-> OK
Unpacking Statistics-R-0.34.tar.gz
Entering Statistics-R-0.34
Checking configure dependencies from META.yml
Checking if you have ExtUtils::MakeMaker 6.59 ... Yes (7.10)
Configuring Statistics-R-0.34
Running Makefile.PL
Locating bin:R... found at /usr/local/bin/R.
Checking if your kit is complete...
Looks good
Generating a Unix-style Makefile
Writing Makefile for Statistics::R
Writing MYMETA.yml and MYMETA.json
-> OK
Checking dependencies from MYMETA.json ...
Checking if you have Text::Balanced 1.97 ... Yes (2.03)
Checking if you have IPC::Run 0.1 ... Yes (0.94)
Checking if you have ExtUtils::MakeMaker 0 ... Yes (7.10)
Checking if you have Regexp::Common 0 ... Yes (2017060201)
Checking if you have Text::Wrap 0 ... Yes (2013.0523)
Checking if you have version 0.77 ... Yes (0.9909)
Checking if you have Test::More 0.47 ... Yes (1.001014)
Building and testing Statistics-R-0.34
cp lib/Statistics/R/Legacy.pm blib/lib/Statistics/R/Legacy.pm
cp lib/Statistics/R.pm blib/lib/Statistics/R.pm
cp lib/Statistics/R/Win32.pm blib/lib/Statistics/R/Win32.pm
Manifying 3 pod documents
PERL_DL_NONLAZY=1 "/Users/azuma.satoshi/.plenv/versions/5.22/bin/perl5.22.0" "-MExtUtils::Command::MM" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; test_harness(0, 'inc', 'blib/lib', 'blib/arch')" t/*.t
# Testing Statistics::R 0.34, Perl 5.022000, /Users/azuma.satoshi/.plenv/versions/5.22/bin/perl5.22.0
t/00-load.t ........ ok
t/01-pod.t ......... ok
t/02-legacy.t ...... ok
# R version 3.4.3 found at /usr/local/bin/R
t/03-run.t ......... ok
t/04-start-stop.t .. ok
t/05-shared.t ...... ok
t/06-get-set.t ..... ok
t/07-robust.t ...... ok
# Failed test 'Runtime error'
# at t/08-errors.t line 26.
# Looks like you failed 1 test of 12.
t/08-errors.t ......
Dubious, test returned 1 (wstat 256, 0x100)
Failed 1/12 subtests
Test Summary Report
-------------------
t/08-errors.t (Wstat: 256 Tests: 12 Failed: 1)
Failed test: 5
Non-zero exit status: 1
Files=9, Tests=10209, 11 wallclock secs ( 0.68 usr 0.13 sys + 10.16 cusr 1.14 csys = 12.11 CPU)
Result: FAIL
Failed 1/9 test programs. 1/10209 subtests failed.
make: *** [test_dynamic] Error 1
-> FAIL Installing Statistics::R failed. See /Users/azuma.satoshi/.cpanm/work/1519699952.55772/build.log for details. Retry with --force to force install it.
######
Then, I compared test result that execute without LANG and one with LANG=C.
######
$ prove -Ilib t/08-errors.t
t/08-errors.t .. 5/?
# Failed test 'Runtime error'
# at t/08-errors.t line 26.
t/08-errors.t .. 12/? # Looks like you failed 1 test of 12.
t/08-errors.t .. Dubious, test returned 1 (wstat 256, 0x100)
Failed 1/12 subtests
Test Summary Report
-------------------
t/08-errors.t (Wstat: 256 Tests: 12 Failed: 1)
Failed test: 5
Non-zero exit status: 1
Files=1, Tests=12, 2 wallclock secs ( 0.02 usr 0.01 sys + 0.89 cusr 0.19 csys = 1.11 CPU)
Result: FAIL
$ LANG=C prove -Ilib t/08-errors.t
t/08-errors.t .. ok
All tests successful.
Files=1, Tests=12, 2 wallclock secs ( 0.02 usr 0.01 sys + 0.87 cusr 0.18 csys = 1.08 CPU)
Result: PASS
######
Finally, I compared result of illegal syntax on R without LANG and one on R with LANG=C.
######
$ R --no-save
R version 3.4.3 (2017-11-30) -- "Kite-Eating Tree"
Copyright (C) 2017 The R Foundation for Statistical Computing
Platform: x86_64-apple-darwin15.6.0 (64-bit)
R は、自由なソフトウェアであり、「完全に無保証」です。
一定の条件に従えば、自由にこれを再配布することができます。
配布条件の詳細に関しては、'license()' あるいは 'licence()' と入力してください。
R は多くの貢献者による共同プロジェクトです。
詳しくは 'contributors()' と入力してください。
また、R や R のパッケージを出版物で引用する際の形式については
'citation()' と入力してください。
'demo()' と入力すればデモをみることができます。
'help()' とすればオンラインヘルプが出ます。
'help.start()' で HTML ブラウザによるヘルプがみられます。
'q()' と入力すれば R を終了します。
Show quoted text
> print(asdf)
print(asdf) でエラー: オブジェクト 'asdf' がありません
Show quoted text> q()
$ LANG=C R --no-save
R version 3.4.3 (2017-11-30) -- "Kite-Eating Tree"
Copyright (C) 2017 The R Foundation for Statistical Computing
Platform: x86_64-apple-darwin15.6.0 (64-bit)
R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.
R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.
Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.
Show quoted text> print(asdf)
Error in print(asdf) : object 'asdf' not found
Show quoted text> q()
######
For these reasons, t/08-errors.t be considered to depend to language setting of system.
Best regards.
--
Satoshi AZUMA [PAUSE:YTURTLE] <ytnobody@gmail.com>