Commit Graph

7093 Commits

Author SHA1 Message Date
Justin M. Keyes
0ce77a744a Merge #5749 from justinmk/test-ctrl-c 2017-01-04 13:32:39 +01:00
Anmol Sethi
d8a97d7b79 man.vim: do not set ft=man on files with extension man (#5831)
Closes #5806
2017-01-04 13:01:03 +01:00
Justin M. Keyes
6f9be2464c Merge #5872 justinmk/test_autochdir 2017-01-04 08:24:36 +01:00
Justin M. Keyes
af828f2257 Merge #5864 from ZyX-I/fix-5857
unittest: Allow multiple indirect includes
2017-01-04 11:54:11 +01:00
Justin M. Keyes
a63675c384 test/helpers.rmdir(): Windows: Change to top-level dir on failure.
On Windows, if the nvim process has a directory open the lua process
cannot remove it. After failing once, it's safe to force `nvim` to the
top-level directory. Then try again.
2017-01-04 07:23:13 +01:00
Justin M. Keyes
e43f7425ee refactor: Remove VimL function test()
vim-patch:7.4.1838
2017-01-04 07:23:13 +01:00
Justin M. Keyes
097c8dccca refactor: Remove VimL function test_autochdir()
- Eliminate global test_autochdir.
- Eliminate VimL function test_autochdir()
- Use a lua test instead. Fails correctly after reverting
  0c43479979 / vim-patch:7.4.2015.
2017-01-04 07:23:13 +01:00
lonerover
c56411ed87 vim-patch:7.4.2043 (#5871)
Problem:    setbuvfar() causes a screen redraw.
Solution:   Only use aucmd_prepbuf() for options.

93431df9eb
2017-01-04 06:16:21 +01:00
Justin M. Keyes
e03b43bd07 test: skip_fragile(), TEST_SKIP_FRAGILE
Let build systems define TEST_SKIP_FRAGILE to skip tests that are known to be
resource-intensive (unreliable on slow systems).

References https://github.com/neovim/neovim/pull/5488#issuecomment-265622113
2017-01-04 04:24:18 +01:00
Justin M. Keyes
f4d326cf10 test: ctrl_c_spec
- Improve test reliability by only checking for a line with the string
  we are interested in ("Interrupt").
- Try to avoid OOM by loading an existing big file instead of looping to
  create one.
2017-01-04 03:18:30 +01:00
Marco Hinz
15259c4b84 clipboard: show error message only once and put in history (#5870) 2017-01-04 00:45:31 +01:00
Shougo
9cb31ecdb0 syntax/ruby.vim, perl.vim: Preserve 'foldmethod'. (#5858) 2017-01-03 23:53:59 +01:00
ZyX
937b6fac8f unittest: Fix linter errors 2017-01-03 22:54:55 +03:00
ZyX
b38e725428 unittest: Refactor preprocess.lua
Keeps arguments separated and not joined as a single string as long as possible. 
Abstracts away additional arguments so that Gcc:preprocess should work for 
compilers with different conventions should they be supported.
2017-01-03 22:54:55 +03:00
ZyX
2151ddbd73 unittest: Move nil checks to Gcc:preprocess 2017-01-03 22:54:54 +03:00
ZyX
0d7b779cab unittest: Record previous defines in another place
Previous commit made preprocess.lua know how its output will be used. This moves 
state to cimport, making only it know which is cleaner.
2017-01-03 22:54:54 +03:00
ZyX
410d18ef5c unittest: Allow multiple indirect includes
Works by saving all preprocessor defines and reusing them on each run. This also
saves NVIM_HEADER_H defines. Saving other defines is needed for defines like
`Map(foo, bar)` which are sometimes used to declare types or functions. Saving
types or function declarations is not needed because they are recorded as luajit
state.

Fixes #5857
2017-01-03 22:54:54 +03:00
James McCoy
3b793d0453 Merge pull request #5835 from lonerover/vim-7.4.1847
vim-patch:7.4.1847
2017-01-03 11:36:56 -05:00
lonerover
17dc20369e fix lint error 2017-01-03 10:42:44 -05:00
lonerover
1bea73a21e vim-patch:7.4.1847
Problem:    Getting an item from a NULL dict crashes.  Setting a register to a
            NULL list crashes. (Nikolai Pavlov, issue vim/vim#768)  Comparing a NULL
            dict with a NULL dict fails.
Solution:   Properly check for NULL.

13ddc5c359
2017-01-03 10:38:56 -05:00
Tommy Allen
fd9cc8b0b2 automation: Generate API documentation (#5798)
runtime: Add underscore to {} helpSpecial syntax pattern

docs: Added generated api-funcs.txt
2017-01-03 13:11:19 +01:00
James McCoy
efe1476d42 Merge pull request #5743 from jamessan/na-vim-patches
version.c: Mark NA patches
2017-01-02 13:57:26 -05:00
James McCoy
af2b5abcd6
lint 2017-01-02 07:18:18 -05:00
James McCoy
9264f4cbbb
Mark 'execute()' patches applied
vim-patch:7.4.1996

Problem:    Capturing the output of a command takes a few commands.
Solution:   Add evalcmd().

1e5e1231ac

vim-patch:7.4.1999

Problem:    evalcmd() doesn't work recursively.
Solution:   Use redir_evalcmd instead of redir_vname.

bc5d6dd1dd

vim-patch:7.4.2000

Problem:    Evalcmd test fails.
Solution:   Add missing piece.

245a7cb6d3

vim-patch:7.4.2005

Problem:    After using evalcmd() message output is in the wrong position.
            (Christian Brabandt)
Solution:   Reset msg_col.

ee1deb4a00
2017-01-02 07:11:02 -05:00
James McCoy
5b8bdca564
vim-patch:7.4.1861
Problem:    Compiler warnings with 64 bit compiler.
Solution:   Change int to size_t. (Mike William)

b055066a1d

Functional changes had already been made when package feature was
initially merged.
2017-01-02 07:11:02 -05:00
James McCoy
94a08e8186
vim-patch:7.4.1839
Problem:    Cannot get the items stored in a partial.
Solution:   Support using get() on a partial.

2bbf8eff6f

The content of this was already applied in the partials PR, but no
commit mentioned the upstream patch.
2017-01-02 07:11:02 -05:00
James McCoy
be177bce8f
vim-patch:7.4.1781
Problem:    synIDattr() does not respect 'guicolors'.
Solution:   Change the conditition for the mode. (Christian Brabandt)

da5b3dcf06
2017-01-02 07:11:02 -05:00
James McCoy
27b5fa59f5
vim-patch:7.4.1656
Problem:    Crash when using partial with a timer.
Solution:   Increment partial reference count. (Hirohito Higashi)

92e35efaf6

The content of this was already applied in the partials PR, but no
commit mentioned the upstream patch.
2017-01-02 07:11:01 -05:00
James McCoy
67d57f6917
version.c: Mark NA patches
- 1727: garbagecollect_for_testing()
- 1761,1762: NA Coverity issue
- 1769: Adding attributes to if_pyth's sys.stdout
- 1812: Athena/Motif GUI fixes
- 1838: Rename of test functions (e.g., garbagecollect_for_testing()) to start with "test_"
- 1844: More test function renames
- 1888: Calculating sleep time for RealWaitForChar
- 1903,1904,1905,1907,1911,1936: viminfo merging
- 1955: Fix for 64-bit Vim linking against 32-bit Perl due to differing time_t
- 1971: settmode() change for Solaris
- 2073: Reading rgb.txt
- 2093: Netbeans test
- 2094: GUI color allocation changes
- 2132, 2198: job tests
2017-01-02 07:10:49 -05:00
James McCoy
f7639e2490 Merge pull request #5859 from jamessan/vim-7.4.1866
vim-patch:7.4.1866,7.4.1868
2017-01-02 06:39:47 -05:00
James McCoy
945540b782
vim-patch:7.4.1868
Problem:    Setting really_exiting causes memory leaks to be reported.
Solution:   Add the in_free_all_mem flag.

b89a25f17e
2017-01-01 23:20:31 -05:00
James McCoy
1feaa450cb
vim-patch:7.4.1866
Problem:    Invalid memory access when exiting with EXITFREE defined.
            (Dominique Pelle)
Solution:   Set "really_exiting" and skip error messages.

a96732150c

This fails to build, due to a00c2e0ecb
removing really_exiting from globals.h, but the next commit fixes the
build failure.
2017-01-01 23:20:24 -05:00
Shougo Matsushita
6ba3b85382 vim-patch:6f1d9a
Updated runtime files.

6f1d9a096b
2017-01-02 10:45:10 +09:00
Shougo Matsushita
0c43479979 vim-patch:7.4.2015
Problem:    When a file gets a name when writing it 'acd' is not effective.
            (Dan Church)
Solution:   Invoke DO_AUTOCHDIR after writing the file. (Allen Haim, closes
            vim/vim#777, closes vim/vim#803)  Add test_autochdir() to enable 'acd' before
            "starting" is reset.

5c71994f4e
2017-01-02 10:43:45 +09:00
James McCoy
c5f4b92ff9 Merge pull request #5613 from jamessan/vim-7.4.2183
vim-patch:7.4.2183,7.4.2194,7.4.2201,7.4.2204,0952131,7.4.2215,7.4.2225,7.4.2226,7.4.2272,7.4.2273,7.4.2277,7.4.2294
2017-01-01 15:12:33 -05:00
Justin M. Keyes
57ce8b5648 Merge #5855 from lonerover/vim-7.4.2019
vim-patch:7.4.2019,7.4.2028
2017-01-01 16:30:21 +01:00
rover
13e2e22073 vim-patch:7.4.2028
Problem:    cppcheck warns for using index before limits check.
Solution:   Swap the expressions. (Dominique Pelle)

5498a41f5a
2017-01-01 23:18:30 +08:00
Shougo
3d3545bbc1 vim-patch:7.4.1834 (#5854)
Problem:    Possible crash when conceal is active.
Solution:   Check for the screen to be valid when redrawing a line.

908be43879
2017-01-01 16:07:49 +01:00
Anmol Sethi
f6c4e0961d man.vim: remove newline from man errors (#5852) 2017-01-01 15:09:27 +01:00
rover
6705652928 vim-patch:7.4.2019
Problem:    When ignoring case utf_fold() may consume a lot of time.
Solution:   Optimize for ASCII.

c4a927ca8d
2017-01-01 21:15:50 +08:00
Justin M. Keyes
61d4ca214f Merge #5804 from brcolow/vim-7.4.1793
vim-patch:7.4.17[83,85,93]
2016-12-31 23:43:49 +01:00
Michael Ennen
137dfdcc4e vim-patch:7.4.1785
Problem:    Regexp test fails on windows.
Solution:   set 'isprint' to the right value for testing.

490465bda6
2016-12-31 14:38:27 -07:00
Michael Ennen
e8ccaa7a52 vim-patch:7.4.1783
Problem:    The old regexp engine doesn't handle character classes correctly.
            (Manuel Ortega)
Solution:   Use regmbc() instead of regc().  Add a test.

af98a49dd0
2016-12-31 14:38:27 -07:00
Michael Ennen
415495273c vim-patch:7.4.1793
Problem:    Some character classes may differ between systems.  On OS/X the
            regexp test fails.
Solution:   Make this less dependent on the system. (idea by Kazunobu Kuriyama)

e8aee7dcf9
2016-12-31 14:38:27 -07:00
lonerover
5366242789 vim-patch:7.4.1970 (#5850)
Problem:    Using ":insert" in an empty buffer sets the jump mark. (Ingo
            Karkat)
Solution:   Don't adjust marks when replacing the empty line in an empty
            buffer. (closes vim/vim#892)

70e136e1d8
2016-12-31 17:32:50 +01:00
lonerover
b37da9c664 vim-patch:7.4.1940 (#5849)
Problem:    "gd" hangs in some situations. (Eric Biggers)
Solution:   Remove the SEARCH_START flag when looping.  Add a test.

23c60f21b0
2016-12-31 17:30:04 +01:00
lonerover
aa35cd9af0 vim-patch:7.4.1876 (#5848)
Problem:    Typing "k" at the hit-enter prompt has no effect.
Solution:   Don't assume recursive use of the prompt if a character was typed.
            (Hirohito Higashi)

a0055ad3a7
2016-12-31 17:27:11 +01:00
Justin M. Keyes
c6a50ca82c test: jobclose(): Avoid indeterminism. (#5851)
stdout activity may reach the queue before `exit`; just discard it.

Observed on Travis CI, ubuntu "trusty" beta image:

    [ RUN      ] ...is/build/neovim/neovim/test/functional/core/job_spec.lua @ 509: jobs running tty-test program jobclose() sends SIGHUP
    ...is/build/neovim/neovim/test/functional/core/job_spec.lua:511: Expected objects to be the same.
    Passed in:
    (table) {
      [1] = 'notification'
     *[2] = 'stdout'
      [3] = {
        [1] = 0
        [2] = {
          [1] = '
    '
          [2] = '' } } }
    Expected:
    (table) {
      [1] = 'notification'
     *[2] = 'exit'
      [3] = {
        [1] = 0
        [2] = 42 } }
    stack traceback:
    	...is/build/neovim/neovim/test/functional/core/job_spec.lua:511: in function <...is/build/neovim/neovim/test/functional/core/job_spec.lua:509>
    [  FAILED  ] ...is/build/neovim/neovim/test/functional/core/job_spec.lua @ 509: jobs running tty-test program jobclose() sends SIGHUP (2.81 ms)
2016-12-31 08:59:44 -05:00
Marco Hinz
d2998a0a49 Tests: make unit tests work on macOS Sierra
Fixes #5455.
2016-12-29 02:58:21 +01:00
James McCoy
46235a30ed
lint 2016-12-28 14:57:40 -05:00