Skip to content

Commit

Permalink
s
Browse files Browse the repository at this point in the history
  • Loading branch information
bstaletic committed Aug 13, 2024
1 parent a460f2c commit 0299d39
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions ycmd/completers/cs/cs_completer.py
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,7 @@ def GetDoc( self, request_data ):
if not hover_value:
raise RuntimeError( 'No documentation available.' )
markdown_stripped = ''.join( hover_value.split( '```' ) )[ 7: ]
markdown_stripped = markdown_stripped.replace( '\n\n\n', '\n' )
return responses.BuildDetailedInfoResponse( markdown_stripped )


Expand Down
4 changes: 2 additions & 2 deletions ycmd/tests/cs/subcommands_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -575,7 +575,7 @@ def test_Subcommands_GetDoc_Variable( self, app ):
response = app.post_json( '/run_completer_command', getdoc_data ).json
assert_that( response,
has_entry( 'detailed_info',
'(field) int GetDocTestCase.an_int\n\n\n'
'(field) int GetDocTestCase.an_int\n'
'an integer, or something' ) )


Expand All @@ -595,7 +595,7 @@ def test_Subcommands_GetDoc_Function( self, app ):
response = app.post_json( '/run_completer_command', getdoc_data ).json
# And here LSP OmniSharp-Roslyn messes up the formatting.
assert_that( response, has_entry( 'detailed_info',
'int GetDocTestCase.DoATest()\n\n\n'
'int GetDocTestCase.DoATest()\n'
'Very important method\\. With multiple lines of '
'commentary And Format\\- \\-ting' ) )

Expand Down

0 comments on commit 0299d39

Please sign in to comment.