YouCompleteMe/python/ycm
zzbot 39fe6d1f86
Auto merge of #2898 - micbou:line-overlapping-chunks, r=micbou
[READY] Apply chunks from bottom to top

Without the proposed fix, the test included in that PR fails as follows
```
FAIL: ycm.tests.vimsupport_test.ReplaceChunksInBuffer_LineOverlappingChunks_test
----------------------------------------------------------------------
Traceback (most recent call last):
  File "C:\Python36\lib\site-packages\nose\case.py", line 198, in runTest
    self.test(*self.arg)
  File "C:\Users\micbou\projects\YouCompleteMe\python\ycm\tests\vimsupport_test.py", line 768, in ReplaceChunksInBuffer_LineOverlappingChunks_test
    AssertBuffersAreEqualAsBytes( expected_buffer, result_buffer )
  File "C:\Users\micbou\projects\YouCompleteMe\python\ycm\tests\vimsupport_test.py", line 86, in AssertBuffersAreEqualAsBytes
    eq_( ToBytes( result_line ), ToBytes( expected_line ) )
AssertionError: b'    third line' != b'    third '
```
Found the issue while trying to add code formatting support to the language server completer. The test is based on a real-world scenario when formatting with jdt.ls (for some reason, jdt.ls is including the newline of the previous line when fixing indentation).

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/valloric/youcompleteme/2898)
<!-- Reviewable:end -->
2018-02-10 15:20:24 -08:00
..
client Add support for Java diagnostics and asynchronous messages 2018-02-10 16:29:27 +00:00
tests Auto merge of #2898 - micbou:line-overlapping-chunks, r=micbou 2018-02-10 15:20:24 -08:00
__init__.py Fixing python tests broken in rename 2013-05-19 20:06:14 -07:00
base.py Rewrite completion system 2017-06-21 02:32:57 +02:00
buffer.py Add support for Java diagnostics and asynchronous messages 2018-02-10 16:29:27 +00:00
diagnostic_filter.py Do not install aliases from future 2017-03-18 18:24:48 +01:00
diagnostic_interface.py Add support for Java diagnostics and asynchronous messages 2018-02-10 16:29:27 +00:00
omni_completer.py Add omnifunc tests 2017-07-07 22:45:05 +02:00
paths.py Drop Python 2.6 and Python 3.3 2018-01-30 18:34:50 +01:00
setup.py Add error messages when ycmd crashed 2016-05-02 23:08:32 +02:00
syntax_parse.py Do not install aliases from future 2017-03-18 18:24:48 +01:00
unsafe_thread_pool_executor.py Update flake8 config 2016-03-06 17:39:55 +00:00
vimsupport.py Auto merge of #2898 - micbou:line-overlapping-chunks, r=micbou 2018-02-10 15:20:24 -08:00
youcompleteme.py Auto merge of #2863 - puremourning:java-async-diagnostics, r=micbou 2018-02-10 12:37:57 -08:00