aboutsummaryrefslogtreecommitdiff
path: root/test
Commit message (Collapse)AuthorAge
* Merge #5918 'vim-patch: 7.4.2006, 7.4.2075, 7.4.2077, 7.4.2117, 7.4.2300, ↵Justin M. Keyes2017-01-16
|\ | | | | | | 7.4.2313, 7.4.2314'.
| * fix test failurelonerover2017-01-09
| |
* | setpos(): Set lowercase mark in other buffers (#5753)Matthew Malcomson2017-01-15
| | | | | | | | | | | | | | | | | | | | | | | | | | Also make setpos("'A", [999, 1, 1, 0]) fail, i.e. return -1 (assuming there is no buffer 999). Fixes #5713 Background: `:help setpos()` mentions an argument `"bufnum"` that determines the buffer a mark should be put in. This argument is respected for uppercase marks, but not for lowercase marks. This is reasonable (though I personally would like `setpos()` to be able to set marks in other buffers), but the help doesn't mention this anywhere. It's also strange that attempting to change buffers with `setpos('.', [bufnr('#'), 1, 1, 0])` alerts the user that having a different buffer is an error, while attempting to set a mark with `setpos("'d", [bufnr('#'), 1, 1, 0])` doesn't tell the user that the `"bufnum"` argument is an error.
* | job: Consume content from rbuffer before invoking the callback againJames McCoy2017-01-14
| | | | | | | | | | | | | | | | | | | | While a job callback is active, it may be invoked again. Since the data handled by the first invocation of the callback hasn't been marked as consumed, the subsequent invocation will see the same data. Reported-by: Daniel Hahler Patch-by: oni-link Closes #5889
* | Merge #5933 from justinmk/dir-bufenterJustin M. Keyes2017-01-13
|\ \ | | | | | | open_buffer(): Raise `BufEnter` for directories.
| * | Windows: enable more testsJustin M. Keyes2017-01-13
| | |
| * | test: BufEnterJustin M. Keyes2017-01-13
| | |
* | | eval: Remove dictwatcher from watchers queue before freeing itJames McCoy2017-01-12
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | This fixes a use-after-free noticed by ASAN which would occur when a dictwatcher was still active on a dictionary when the dictionary was freed. fun! MakeWatch() let d = {'foo': 'bar'} call dictwatcheradd(d, 'foo', function('...')) endfun Patch-by: oni-link Closes #5930
* | inccommand: Preview :sub commands only after the delimiter is presentJames McCoy2017-01-11
| | | | | | | | Closes #5888
* | inccommand: Suppress error reporting when previewing commandsJames McCoy2017-01-11
| | | | | | | | Closes #5912
* | test: system([...]): v:shell_errorJustin M. Keyes2017-01-11
| |
* | system([...]): Set v:shell_error=-1 if not executable.Rui Abreu Ferreira2017-01-11
| | | | | | | | | | | | | | | | Do _not_ set v:shell_error on parameter validation error. system([...]) does not invoke a shell, so this change is somewhat questionable. But `:help v:shell_error` is sufficiently vague to allow -1 in this case.
* | test: system([...])Rui Abreu Ferreira2017-01-11
| |
* | vim-patch:7.4.2008James McCoy2017-01-10
| | | | | | | | | | | | | | | | Problem: evalcmd() has a confusing name. Solution: Rename to execute(). Make silent optional. Support a list of commands. https://github.com/vim/vim/commit/79815f1ec77406f2f21a618c053e5793b597db7a
* | test: Windows: Re-enable shada functional testsRui Abreu Ferreira2017-01-08
| | | | | | | | | | One of the tests remains disabled until we figure out the expected behaviour of mkdir() on Windows when `prot` is passed.
* | XDG: Windows: resolve $LOCALAPPDATA, $TEMP (#5278)Rui Abreu Ferreira2017-01-08
| | | | | | | | | | | | | | | | | | | | After #4964 environment variables in the XDG "fallback" table are no longer expanded. Fallback to correctly expanded $LOCALAPPDATA, $TEMP. If that fails (unlikely), fallback to hard-coded paths (e.g. ~/AppData/Local). Closes #5255
* | Merge #5079 from ZyX-I/shada-save-current-posJustin M. Keyes2017-01-07
|\ \ | | | | | | shada: Save current cursor position before saving jumps
| * | shada: Save current cursor position before saving jumpsZyX2017-01-04
| | |
* | | unittest: Fix linter errorsZyX2017-01-07
| | |
* | | unittest,memory: Fix testsZyX2017-01-07
| | |
* | | unittest: Add failing test for freeing dictionaries in a listZyX2017-01-07
| | |
* | | unittest: Add dict_items functionZyX2017-01-07
| | |
* | | unittest: Add failing test of freeing listsZyX2017-01-07
| | |
* | | unittest: Allow mocking allocator callsZyX2017-01-07
| |/ |/|
* | Merge pull request #5826 from ZyX-I/fix-typval_encodeJames McCoy2017-01-06
|\ \ | | | | | | Refactor eval/typval_encode.h
| * | functests: Add tests for new fixesZyX2017-01-06
| | |
| * | unittests: Fix linter errorsZyX2017-01-03
| | |
| * | tests: Add tests for partials dumpingZyX2017-01-03
| | | | | | | | | | | | | | | Also fixed dumping of partials by encode_vim_to_object and added code which is able to work with partials and dictionaries to test/unit/eval/helpers.lua (mostly copied from #5119, except for partials handling).
| * | eval/typval_encode: Fix infinite loopZyX2017-01-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | Occurs when trying to dump a partial with attached self dictionary which references that partial. “Infinite” loop should normally result in Neovim killed by OOM killer. Also moved the place when partials are unreferenced by clear_tv: from …FUNC_START to …FUNC_END.
* | | path.c: `vim_FullName()`: Fix heap overflow #5737nfnty2017-01-05
| | | | | | | | | | | | | | | | | | - Clarify documentation. - Return `FAIL` and truncate if `fname` is too long. - Add tests.
* | | Merge #5874 from ZyX-I/fix-5482Justin M. Keyes2017-01-04
|\ \ \ | | | | | | | | Fix plugin which opens ShaDa files
| * | | plugin/shada: Handle NUL characters with intchar correctlyZyX2017-01-04
| | | | | | | | | | | | Fixes #5482
| * | | plugin/msgpack: Support character constants like '\0'ZyX2017-01-04
| | |/ | |/|
* | | Merge #5749 from justinmk/test-ctrl-cJustin M. Keyes2017-01-04
|\ \ \ | |/ / |/| |
| * | test: skip_fragile(), TEST_SKIP_FRAGILEJustin M. Keyes2017-01-04
| | | | | | | | | | | | | | | | | | | | | 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
| * | test: ctrl_c_specJustin M. Keyes2017-01-04
| |/ | | | | | | | | | | | | - 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.
* | Merge #5872 justinmk/test_autochdirJustin M. Keyes2017-01-04
|\ \
| * | test/helpers.rmdir(): Windows: Change to top-level dir on failure.Justin M. Keyes2017-01-04
| | | | | | | | | | | | | | | | | | 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.
| * | refactor: Remove VimL function `test_autochdir()`Justin M. Keyes2017-01-04
| |/ | | | | | | | | | | | | - Eliminate global test_autochdir. - Eliminate VimL function test_autochdir() - Use a lua test instead. Fails correctly after reverting 0c4347997954 / vim-patch:7.4.2015.
* | unittest: Fix linter errorsZyX2017-01-03
| |
* | unittest: Refactor preprocess.luaZyX2017-01-03
| | | | | | | | | | | | 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.
* | unittest: Move nil checks to Gcc:preprocessZyX2017-01-03
| |
* | unittest: Record previous defines in another placeZyX2017-01-03
| | | | | | | | Previous commit made preprocess.lua know how its output will be used. This moves state to cimport, making only it know which is cleaner.
* | unittest: Allow multiple indirect includesZyX2017-01-03
|/ | | | | | | | | | 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
* test: jobclose(): Avoid indeterminism. (#5851)Justin M. Keyes2016-12-31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | 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)
* Tests: make unit tests work on macOS SierraMarco Hinz2016-12-29
| | | | Fixes #5455.
* vim-patch:7.4.1768James McCoy2016-12-27
| | | | | | | | Problem: Arguments of setqflist() are not checked properly. Solution: Add better checks, add a test. (Nikolai Pavlov, Hirohito Higashi, closes vim/vim#661) https://github.com/vim/vim/commit/d106e5ba7f10f0d2a14eaefe5d78405044416cb9
* test: quickfix: Move upstream vim quickfix test to src/nvim/testdirJames McCoy2016-12-27
| | | | | Massaging the upstream patches for this test into the lua tests are too cumbersome and slow down patching.
* test: job_spec: Avoid unreliable screen test.Justin M. Keyes2016-12-23
|
* eval.c: set_selfdict(): Fix invalid memory access.Justin M. Keyes2016-12-14
|