@@ -54,7 +54,7 @@ const testMethod = (fn, resultKind, mapOrMaps, keyOrKeys, hitHighlights, expecte
5454 const keys = keyOrKeys instanceof Array ? keyOrKeys : [ keyOrKeys ] ;
5555 describe ( 'and key' + ( keys . length === 1 ? ( ' ' + keys [ 0 ] ) : ( 's ' + JSON . stringify ( keys ) ) )
5656 + ' with ' + ( isUndefined ( filter ) ? 'no filter' : 'filter ' + JSON . stringify ( filter ) ) , ( ) => {
57- const result = fn ( mapOrMaps , keys , hitHighlights , filter , limit ) ;
57+ const result = fn ( mapOrMaps , keys , hitHighlights , filter , false , limit ) ;
5858 let shouldReturn ;
5959 if ( resultKind === 'boolean' ) {
6060 shouldReturn = expected ;
@@ -304,10 +304,9 @@ describe('Metadata', () => {
304304
305305 } ) ;
306306
307- // TODO: check why limit seems not to be working (it returns 2 elements instead of 1)
308- xdescribe ( 'all method with limit' , ( ) => {
307+ describe ( 'all method with limit' , ( ) => {
309308 const testAllWithLimit = ( mapOrMaps , keyOrKeys , expected , limit ) =>
310- testMethod ( Metadata . all , 'value' , mapOrMaps , keyOrKeys , expected , undefined , limit ) ;
309+ testMethod ( Metadata . all , 'value' , mapOrMaps , keyOrKeys , undefined , expected , undefined , limit ) ;
311310
312311 describe ( 'with multiMap and limit' , ( ) => {
313312 testAllWithLimit ( multiMap , 'dc.title' , [ dcTitle1 ] , 1 ) ;
0 commit comments