Menu

#76 @stk_sampcrit_eqi\stk_sampcrit_eqi does not pass tests.

2.5
closed
nobody
None
2017-06-19
2017-06-15
STROH
No

The creator function of stk_sampcrit_eqi class does not pass tests, either on Matlab or on Octave.

Discussion

  • Julien Bect

    Julien Bect - 2017-06-16

    Please be more specific.

    Working on the tip of default (currently: hg id 9144d7eec6da), here is what I see on Matlab R2016b:

    >> stk_init
    >> stk_test stk_sampcrit_eqi
    PASSES 64 out of 64 tests
    

    So, at least on some versions of Matlab, all tests pass. Which version of Matlab are you having problems with? What are the failing tests?

    Now, here is what I see on Octave 4.2.1 (compiled from source, tip of stable):

    >> stk_init
    
    >> stk_test stk_sampcrit_eqi
    ????? stk_sampcrit_eqi does not exist in path
    
    >> test stk_sampcrit_eqi
    ????? stk_sampcrit_eqi does not exist in path
    
    >> stk_runtests ./sampling
    % ... cutting irrelevant output...
    
      stk_sampcrit_eqi.m ................................
    F = <stk_sampcrit_eqi object>
    |
    |              model:  --  (not instantiated)
    |     quantile_order:  0.5
    |   point_batch_size:  1
    |    current_minimum:  Inf
    |
    
    
    F = <stk_sampcrit_eqi object>
    |
    |              model:  <stk_model_gpposterior object>
    |     quantile_order:  0.5
    |   point_batch_size:  1
    |    current_minimum:  1.234
    |
    
    ***** assert (F.current_minimum == 1.234);
    !!!!! test failed
    assert (F.current_minimum == 1.234) failed
    ***** assert (stk_isequal_tolrel (F.current_minimum, 2.077996, 1e-6));
    !!!!! test failed
    assert (stk_isequal_tolrel (F.current_minimum, 2.077996, 1e-6)) failed
    ***** test F.point_batch_size = 'toto';  % char
    !!!!! test failed
    @toto: no function and no method found
     PASS 61/64 FAIL 3
       --> passed 61/64 tests
       --> 4/5 files had no tests
    

    Which version of Octave are you using? Do you see the same failing tests?

     
  • STROH

    STROH - 2017-06-19

    OK, I do not know what changed, but now, it works on Matlab version 8.1.0 and Octave version 4.2.1.
    Problem solved.

     
  • Julien Bect

    Julien Bect - 2017-06-19

    Cool. The problems were in the unit tests themselves.

     
  • Julien Bect

    Julien Bect - 2017-06-19
    • status: open --> closed