@@ -480,6 +480,62 @@ def test_GenericLSPCompleter_HoverIsList( self, app, *args ):
480480
481481
482482
483+ @IsolatedYcmd ( { 'language_server' :
484+ [ { 'name' : 'foo' ,
485+ 'filetypes' : [ 'foo' ],
486+ 'project_root_files' : [ '*root' ],
487+ 'cmdline' : [ 'node' , PATH_TO_GENERIC_COMPLETER , '--stdio' ] } ] } )
488+ def test_GenericLSPCompleter_DebugInfo_CustomRootGlob ( self , app , * args ):
489+ test_file = PathToTestFile (
490+ 'generic_server' , 'foo' , 'bar' , 'baz' , 'test_file' )
491+ request = BuildRequest ( filepath = test_file ,
492+ filetype = 'foo' ,
493+ line_num = 1 ,
494+ column_num = 1 ,
495+ contents = '' ,
496+ event_name = 'FileReadyToParse' )
497+
498+ app .post_json ( '/event_notification' , request )
499+ WaitUntilCompleterServerReady ( app , 'foo' )
500+ request .pop ( 'event_name' )
501+ response = app .post_json ( '/debug_info' , request ).json
502+ assert_that (
503+ response ,
504+ has_entry ( 'completer' , has_entries ( {
505+ 'name' : 'GenericLSP' ,
506+ 'servers' : contains_exactly ( has_entries ( {
507+ 'name' : 'fooCompleter' ,
508+ 'is_running' : instance_of ( bool ),
509+ 'executable' : contains_exactly ( instance_of ( str ),
510+ instance_of ( str ),
511+ instance_of ( str ) ),
512+ 'address' : None ,
513+ 'port' : None ,
514+ 'pid' : instance_of ( int ),
515+ 'logfiles' : contains_exactly ( instance_of ( str ) ),
516+ 'extras' : contains_exactly (
517+ has_entries ( {
518+ 'key' : 'Server State' ,
519+ 'value' : instance_of ( str ),
520+ } ),
521+ has_entries ( {
522+ 'key' : 'Project Directory' ,
523+ 'value' : PathToTestFile ( 'generic_server' , 'foo' ),
524+ } ),
525+ has_entries ( {
526+ 'key' : 'Open Workspaces' ,
527+ 'value' : has_items (),
528+ } ),
529+ has_entries ( {
530+ 'key' : 'Settings' ,
531+ 'value' : '{}'
532+ } ),
533+ )
534+ } ) ),
535+ } ) )
536+ )
537+
538+
483539 @IsolatedYcmd ( { 'language_server' :
484540 [ { 'name' : 'foo' ,
485541 'filetypes' : [ 'foo' ],
0 commit comments