File tree 1 file changed +0
-38
lines changed
src/plugins/persistence/couch
1 file changed +0
-38
lines changed Original file line number Diff line number Diff line change @@ -373,44 +373,6 @@ describe('the plugin', () => {
373
373
expect ( requestMethod ) . toEqual ( 'PUT' ) ;
374
374
} ) ;
375
375
} ) ;
376
- describe ( 'implements server-side search' , ( ) => {
377
- let mockPromise ;
378
- beforeEach ( ( ) => {
379
- mockPromise = Promise . resolve ( {
380
- body : {
381
- getReader ( ) {
382
- return {
383
- read ( ) {
384
- return Promise . resolve ( {
385
- done : true ,
386
- value : undefined
387
- } ) ;
388
- }
389
- } ;
390
- }
391
- }
392
- } ) ;
393
- fetch . and . returnValue ( mockPromise ) ;
394
- } ) ;
395
-
396
- it ( "using Couch's 'find' endpoint" , async ( ) => {
397
- await Promise . all ( openmct . objects . search ( 'test' ) ) ;
398
- const requestUrl = fetch . calls . mostRecent ( ) . args [ 0 ] ;
399
-
400
- // we only want one call to fetch, not 2!
401
- // see https://github.com/nasa/openmct/issues/4667
402
- expect ( fetch ) . toHaveBeenCalledTimes ( 1 ) ;
403
- expect ( requestUrl . endsWith ( '_find' ) ) . toBeTrue ( ) ;
404
- } ) ;
405
-
406
- it ( 'and supports search by object name' , async ( ) => {
407
- await Promise . all ( openmct . objects . search ( 'test' ) ) ;
408
- const requestPayload = JSON . parse ( fetch . calls . mostRecent ( ) . args [ 1 ] . body ) ;
409
-
410
- expect ( requestPayload ) . toBeDefined ( ) ;
411
- expect ( requestPayload . selector . model . name . $regex ) . toEqual ( '(?i)test' ) ;
412
- } ) ;
413
- } ) ;
414
376
} ) ;
415
377
416
378
describe ( 'the view' , ( ) => {
You can’t perform that action at this time.
0 commit comments