dod38fr / config-model

Perl module to create configuration editor with semantic validation
58 stars 12 forks source link

Config-Model-Backend-Augeas-0.121 test failures #14

Closed eserte closed 7 years ago

eserte commented 7 years ago

I see the following test failure, probably only if Config::Model::Itself is not installed:

In class:"MasterModel::SshdWithAugeas": (function 'create_element') unknown element 'rw_config'. Either your file has an error or Itself::Class model is lagging behind. In the latter case, please submit a bug report to https://github.com/dod38fr/config-model/issues. See cme man page for details.
    Expected elements: 'class_description','license','author','copyright','class','element','include','include_backend','include_after','generated_by','read_config','write_config','accept'

# Looks like your test exited with 255 just after 2.
t/model_extension.t ...... 
Dubious, test returned 255 (wstat 65280, 0xff00)
Failed 1/3 subtests 
dod38fr commented 7 years ago

Weird. This test should be skipped when Config::Model::Itself in not installed, i.e. like in this report:

Output from './Build test':

t/augeas_backend.t ....... ok
t/augeas_from_scratch.t .. ok
t/model_extension.t ...... skipped: Config::Model::Itself is not installed
t/pod.t .................. ok
All tests successful.
Files=4, Tests=24,  4 wallclock secs ( 0.03 usr  0.03 sys +  2.58 cusr  0.41 csys =  3.05 CPU)
Result: PASS

This looks like an old version of Config::Model::Itself is found, but is not listed as part of the test environment.

eserte commented 7 years ago

Probably my first suggestion was wrong --- it's more likely that an older Config::Model::Itself (2.010? 2.009?) was installed on the failing configurations.

dod38fr commented 7 years ago

yes, but Config::Model::Itself module is not listed in the test report (see below).

I guess Config::Model::Itself is present because of a previous test run where it was needed.


requires:

    Module            Need  Have    
    ----------------- ----- --------
    Config::Augeas    0.303 1.000   
    Config::Model     2.111 2.112   
    Exception::Class  0     1.43    
    Log::Log4perl     1.11  1.49    
    Mouse             0     v2.4.10 

build_requires:

    Module            Need  Have    
    ----------------- ----- --------
    Test::Differences 0     0.64    
    Test::Exception   0     0.43    
    Test::More        0     1.302096
    Test::Warn        0.11  0.32    
    version           0.77  0.9918  

configure_requires:

    Module            Need  Have    
    ----------------- ----- --------
    Module::Build     0.36  0.4224  
eserte commented 7 years ago

Actually, if a requirement is not listed in Makefile.PL, Build.PL or {,MY}META.*, then it won't be listed in the CPAN Testers Report.

dod38fr commented 7 years ago

Right... I guess that the best way is to update the tests to have a build dependency on Config::Model::Itself. That will take care of all this corner case.

Thanks for the report

dod38fr commented 7 years ago

Fixed in Config::Model::Backend::Augeas 0.122.

Thanks for the report