4

私は本当にこれを理解することはできません。明らかに、zefモジュールのある種の配置とプリコンパイルを実行しますが、この場合、コードの異なるバージョンを使用しているように見えるだけなので、これは非常に重要です。たとえば、失敗したテストの 1 つを実行すると、

raku -Ilib t/01-basic.t # ok 1 - get-all() found Licenses

ただし、zef test .そのテストに失敗します(およびローカルで実行した場合にも機能する他の多くのテスト)

➜  License-Software-mine git:(master) ✗ zef test .
===> Testing: License::Software:ver<0.3.0>:auth<kalkin>
[License::Software] # Failed test 'get-all() found Licenses'
[License::Software] # at t/01-basic.t line 8
[License::Software] # You failed 1 test of 1
[License::Software] Can not find license alias 'gplv3'
[License::Software]   in sub license at /home/jmerelo/progs/forks/perl6/License-Software-mine/lib/License/Software.pm6 (License::Software) line 174
[License::Software] # Failed test at t/10-gplv3.t line 8
[License::Software] Method 'aliases' must be implemented by License::Software::Abstract because it is required by roles: .
[License::Software]   in block <unit> at t/10-gplv3.t line 9
[License::Software] # You planned 10 tests, but ran 1
[License::Software] # You failed 1 test of 1
[License::Software] Can not find license alias 'apache'
[License::Software]   in sub license at /home/jmerelo/progs/forks/perl6/License-Software-mine/lib/License/Software.pm6 (License::Software) line 174
[License::Software] Method 'aliases' must be implemented by License::Software::Abstract because it is required by roles: .
[License::Software]   in block <unit> at t/11-Apache2.t line 10
[License::Software] Can not find license alias 'lgplv3'
[License::Software]   in sub license at /home/jmerelo/progs/forks/perl6/License-Software-mine/lib/License/Software.pm6 (License::Software) line 174
[License::Software] # Failed test at t/12-LGPLv3.t line 8
[License::Software] Method 'aliases' must be implemented by License::Software::Abstract because it is required by roles: .
[License::Software]   in block <unit> at t/12-LGPLv3.t line 9
[License::Software] # You planned 8 tests, but ran 1
[License::Software] # You failed 1 test of 1
[License::Software] Can not find license alias 'agplv3'
[License::Software]   in sub license at /home/jmerelo/progs/forks/perl6/License-Software-mine/lib/License/Software.pm6 (License::Software) line 174
[License::Software] # Failed test at t/13-AGPLv3.t line 7
[License::Software] Method 'aliases' must be implemented by License::Software::Abstract because it is required by roles: .
[License::Software]   in block <unit> at t/13-AGPLv3.t line 8
[License::Software] # You planned 11 tests, but ran 1
[License::Software] # You failed 1 test of 1
[License::Software] Can not find license alias 'artistic'
[License::Software]   in sub license at /home/jmerelo/progs/forks/perl6/License-Software-mine/lib/License/Software.pm6 (License::Software) line 174
[License::Software] # Failed test at t/14-Artistic2.t line 7
[License::Software] Method 'aliases' must be implemented by License::Software::Abstract because it is required by roles: .
[License::Software]   in block <unit> at t/14-Artistic2.t line 8
[License::Software] # You planned 8 tests, but ran 1
[License::Software] # You failed 1 test of 1
===> Testing [FAIL]: License::Software:ver<0.3.0>:auth<kalkin>
Aborting due to test failure: License::Software:ver<0.3.0>:auth<kalkin> (use --force-test to override)

zef install .同じように失敗します。これが発生する理由と、回避策があるかどうかの考えはありますか?

4

1 に答える 1

7

zef は使用しません-Ilib-- 私は個人的に、人々にそれを使用するように言うのは有害だと考えています -- 使用します-I.

➜  License-Software git:(master) raku -Ilib t/01-basic.t
1..1
ok 1 - get-all() found Licenses
➜  License-Software git:(master) raku -I. t/01-basic.t
1..1
not ok 1 - get-all() found Licenses
# Failed test 'get-all() found Licenses'
# at t/01-basic.t line 8
# You failed 1 test of 1

明らかに、zef 自体はプリコンパイルを行っておらず、別のバージョンのコードも使用していません。プラグイン モジュールも使用しており、すべてのエラーは接続されているものを参照しています。したがって、使用しているプラ​​グイン コードは-I..

于 2020-08-28T15:04:35.583 に答える