Commit Graph

13382 Commits

Author SHA1 Message Date
Daniel Hahler
f1f9a2f97b
tests: improve RunTests.cmake (#10239)
- allow for passing in BUSTED_ARGS via env
- quote values of TEST_TAG/TEST_FILTER

  Previously TEST_FILTER="'foo bar'" was required.

This allows for:

    make functionaltest TEST_FILE=test/functional/terminal/tui_spec.lua \
      BUSTED_ARGS="--no-keep-going --shuffle" \
      TEST_FILTER="TUI background color handles"

* RunTests.cmake: BUILD_DIR for Xtest files, isolated TMPDIR

Assume relative path for given TEST_PATH.
2019-06-22 06:44:52 +02:00
Daniel Hahler
058a8ed6ec build: USE_BUNDLED_LUV=0 with USE_BUNDLED_LUAROCKS=1 #10291
Fixes https://github.com/neovim/neovim/issues/10289
2019-06-22 03:43:31 +02:00
Daniel Hahler
aa090f9801
cmake: fix usage of find_package_handle_standard_args (#10288)
The package argument is case sensitive, which is important to handle
X_FIND_REQUIRED properly, i.e. error out early if it is not found:

    CMake Error at /usr/share/cmake-3.14/Modules/FindPackageHandleStandardArgs.cmake:137 (message):
      Could NOT find Unibilium (missing: UNIBILIUM_LIBRARY UNIBILIUM_INCLUDE_DIR)

Otherwise it would continue until:

    CMake Error: The following variables are used in this project, but they
    are set to NOTFOUND.
    Please set them or make sure they are set and tested correctly in the
    CMake files:
    UNIBILIUM_INCLUDE_DIR (ADVANCED)

Quickly checked via `rg 'find_package_handle_standard|find_package.*REQUIRED' -I | sort`.

Ref: https://gitlab.kitware.com/cmake/cmake/issues/19413
2019-06-21 03:48:46 +02:00
Daniel Hahler
e28a7a366d CI/Travis: restore ASAN build to first stage #10274
* ci: Travis: move ASAN build to first stage again
  Ref: https://github.com/neovim/neovim/pull/10238#issuecomment-503556762
* rename stages
* move gcov to second stage, restore order
2019-06-20 01:51:41 +02:00
Justin M. Keyes
954df0ea03
Merge #10245 from janlazo/vim-8.0.1723
vim-patch:8.0.{1723,1726,1735},8.1.{73,74}
2019-06-19 23:46:43 +02:00
Daniel Hahler
487eaf8d45 CI: use -m to invoke pip #10275
Also install "pynvim" instead of "neovim".

Ref: https://github.com/neovim/neovim/pull/10228#discussion_r295266859
2019-06-19 20:28:37 +02:00
erw7
3f48b3a92f Update argc(),argv() based on 8.1.0493 2019-06-19 01:36:01 -04:00
Jan Edmund Lazo
516eb9bf9d test/old: run test_arglist
Run failing tests, added in vim-patch:8.1.0493.
2019-06-19 01:36:01 -04:00
Jan Edmund Lazo
5c2feb690e vim-patch:8.1.0074: crash when running quickfix tests
Problem:    Crash when running quickfix tests.
Solution:   Do not alloc a new location list when checking for the reference
            to be still valid.
d6b01a2d38
2019-06-19 01:36:00 -04:00
Jan Edmund Lazo
a6707f5791 vim-patch:8.1.0073: crash when autocommands call setloclist()
Problem:    Crash when autocommands call setloclist(). (Dominique Pelle)
Solution:   If the quickfix list changes then don't jump to the error.
0366c0161e
2019-06-19 01:36:00 -04:00
Jan Edmund Lazo
8bea8d7b47 vim-patch:8.0.1726: older MSVC doesn't support declarations halfway a block
Problem:    Older MSVC doesn't support declarations halfway a block.
Solution:   Move the declaration back to the start of the block.
df2c774ded
2019-06-19 01:36:00 -04:00
Jan Edmund Lazo
315076a26d vim-patch:8.0.1723: using one item array size declaration is misleading
Problem:    Using one item array size declaration is misleading.
Solution:   Instead of using "[1]" and actually using a larger array, use
            "[]".  This is to verify that this C99 feature works for all
            compilers.
f3a411783c

The following patch is N/A because Neovim requires C99.
vim-patch:8.0.1735: flexible array member feature not supported by HP-UX
2019-06-19 01:36:00 -04:00
Daniel Hahler
352d5a9713
ci: Travis: move gcov job to baseline (no allowed failures) (#10238)
* ci: Travis: move gcov job to baseline (no allowed failures)

* ci: Travis: use two stages only

Moves CLANG_SANITIZER=ASAN_UBSAN to second stage.
2019-06-19 01:20:09 +02:00
Daniel Hahler
59b2b1c955
tests: oldtests: mark Test_cursorhold_insert as flaky [ci skip] (#10264)
Fails often on CI (OSX), e.g.:

```
1 FAILED:
Found errors in Test_cursorhold_insert():
function RunTheTest[37]..Test_cursorhold_insert line 9: Expected 1 but got 0
```

> Compiler: clang Xcode: xcode10.1 C

The test could be adjusted to re-try the timer a few times, but I do not
think it's really worth it currently, and that the test should be marked
as flaky instead.
2019-06-19 01:19:20 +02:00
Daniel Hahler
c6ce40bf37
ci: Travis: simplify/improve Python/pip setup (#10228)
* ci/before_install.sh: do not (try to) upgrade pip

  It is not necessary usually (for our use case(s)), and rather good to
  have this (implicitly) pinned.

* Simplify/improve Python info output

* Use pyenv-global to activate/use Python 2.7/7.7

* simplify pip-install of neovim, also for osx
2019-06-18 20:13:47 +02:00
Björn Linse
149dcbf2c7
Merge pull request #10021 from bfredl/chanevent
channel: refactor events, prevent recursive invocation of callbacks
2019-06-18 13:58:14 +02:00
Björn Linse
d4938743e6 channel: refactor events, prevent recursive invocation of events 2019-06-18 10:49:38 +02:00
Daniel Hahler
25e04c1d98
gcov: use __gcov_flush instead of __gcov_dump (#10260)
This restores missing coverage again.

Move it to process_spawn in os/pty_process_unix.c, since it seems to
break printargs-test on Windows/AppVeyor otherwise (#10248).
2019-06-18 06:31:57 +02:00
Justin M. Keyes
4946751906
Merge #10224 from blueyed/fix-Test_tagfiles
tests: fix Test_tagfiles: use Vim's 'tags' setting
2019-06-17 12:08:56 -07:00
Daniel Hahler
5edced0a86
Merge pull request #10186 from blueyed/fix-cd
ci: minor improvements
2019-06-17 20:55:02 +02:00
Daniel Hahler
bd3242a70f ci: Travis: skip lint job with "\[skip.lint\]" 2019-06-17 02:00:58 +02:00
Daniel Hahler
185fc775b9 ci: Travis: ccache: use --zero-stats
This makes it display actual results in before_cache then, and it seems
like it is not necessary to keep stats across builds.
2019-06-17 02:00:58 +02:00
Daniel Hahler
755e94801f ci: AppVeyor: use fast_finish=true 2019-06-17 02:00:58 +02:00
Daniel Hahler
3dab5f625f ci/build.ps1: add comment for PATH mangling with old tests 2019-06-17 02:00:58 +02:00
Daniel Hahler
b98b1168d8 ci: Travis: remove obsolete cmake file
Added in f65614fb1, forgot to be removed in 55682710a.
2019-06-17 02:00:58 +02:00
Daniel Hahler
04d03b0cbc ci/common/test.sh: fix some issues reported by shellcheck 2019-06-17 02:00:58 +02:00
Daniel Hahler
c6602df015 vim-patch:8.1.1546: in some tests 'tags' is set but not restored
Problem:    In some tests 'tags' is set but not restored. (Daniel Hahler)
Solution:   Restore 'tags'. (closes vim/vim#4535)
0331faf712
2019-06-16 19:51:12 +02:00
Daniel Hahler
3d8e8cb889 tests: fix Test_tagfiles: use Vim's 'tags' setting
Otherwise it might fail with an existing `tags` file upwards, e.g. in
neovim's source directory (which should be rather common).
2019-06-16 19:51:12 +02:00
Daniel Hahler
d32b92e265
vim-patch:8.0.1845: various comment updates needed, missing white space (#10203)
Problem:    Various comment updates needed, missing white space.
Solution:   Update comments, add white space.
259f26ac2d

Ignored (partly) applied patch for src/nvim/po/it.po.
2019-06-16 19:49:23 +02:00
Daniel Hahler
491a3210a9
vim-patch:8.1.1003: playing back recorded key sequence mistakes key code (#10155)
Problem:    Playing back recorded key sequence mistakes key code.
Solution:   Insert a <Nop> after the <Esc>. (closes vim/vim#4068)
6edbbd8114
2019-06-16 19:48:46 +02:00
Daniel Hahler
d792d4ec06
Merge pull request #10236 from janlazo/vim-8.1.1545
vim-patch:8.0.{1516,1549},8.1.{0044,1545}
2019-06-16 17:52:38 +02:00
Björn Linse
3d6e48a941
Merge pull request #10150 from bfredl/extcount
make msg_advance and search_count not crash with ext_messages, fixes #10069
2019-06-16 12:34:27 +02:00
Björn Linse
e39d217592 messages: fix crash with msg_advance when using ext_messages 2019-06-16 11:31:35 +02:00
Björn Linse
41f31ca90d messages: support shortmess-=S in ext_messages 2019-06-16 11:07:29 +02:00
Jan Edmund Lazo
cb01925eb4 vim-patch:8.0.1549: various small problems in test files
Problem:    Various small problems in test files.
Solution:   Include small changes.
5d7ead3bc8
2019-06-15 22:24:59 -04:00
Jan Edmund Lazo
b837c56576 vim-patch:8.0.1516: errors for job options are not very specific
Problem:    Errors for job options are not very specific.
Solution:   Add more specific error messages.
b3292fa2d3
2019-06-15 22:14:29 -04:00
Jan Edmund Lazo
c6c5754a86 vim-patch:8.1.0044: if a test function exists Vim this may go unnoticed
Problem:    If a test function exists Vim this may go unnoticed.
Solution:   Check for a test funtion quitting Vim.  Fix tests that did exit
            Vim.
8903676d3d

Restore test_assert.vim to run Test_zz_quit_detected().
2019-06-15 21:48:27 -04:00
Jan Edmund Lazo
1abfeff978 vim-patch:8.1.1545: when the screen is to small there is no message about that
Problem:    When the screen is to small there is no message about that.
            (Daniel Hahler)
Solution:   Do not use :cquit. (closes vim/vim#4534)
45aa07d3c1
2019-06-15 21:48:27 -04:00
Daniel Hahler
5a96161e86
ci: AppVeyor: ensure that win32 feature is set (#10216)
[skip travis]

Closes https://github.com/neovim/neovim/pull/10232.

Co-authored-by: Jan Edmund Lazo <jan.lazo@mail.utoronto.ca>
2019-06-16 02:33:47 +02:00
Jan Edmund Lazo
b60c986a49 vim-patch:8.0.1245: when WaitFor() has a wrong expression it just waits a second (#10233)
Problem:    When WaitFor() has a wrong expression it just waits a second,
            which goes unnoticed. (James McCoy)
Solution:   When WaitFor() times out throw an exception.  Fix places where the
            expression was wrong.
3e1c617d49
2019-06-15 18:56:55 +02:00
Daniel Hahler
5d5e16c2ed
ci: Travis: add baseline stage [skip appveyor] (#10226)
This moves the 4 fastest jobs there, effectively resulting in a separate
OSX stage then.

Travis typically runs 4/5 jobs in parallel, so this avoids a) running the
slower OSX builds if there are problems already, and b) will start other
builds already earlier (e.g. after the lint job finished).
2019-06-15 18:46:51 +02:00
Daniel Hahler
26a9d2cef1
ci: codecov: do not use flags [ci skip] (#10227)
Using flags results in timeouts on their end when viewing reports, and
is a known issue since months already.
2019-06-15 18:34:00 +02:00
Daniel Hahler
d3d25f957d
Dump gcov coverage in process_spawn (#10230)
Fixes https://github.com/neovim/neovim/pull/3926#issuecomment-502343527.
2019-06-15 18:30:04 +02:00
Björn Linse
2f1a653a84
Merge pull request #10231 from bfredl/bufcb_end
api/lua: add on_detach to nvim_buf_attach
2019-06-15 15:59:45 +02:00
Björn Linse
64cdf9f78a api/lua: add on_detach to nvim_buf_attach 2019-06-15 13:19:12 +02:00
Daniel Hahler
93f8c2793c
ci: AppVeyor: fix cov job, remove duplicate non-cov one (#10217)
* ci: AppVeyor: set GCOV_ERROR_FILE

This prevents the warnings/errors to be spilled into test results,
causing them to fail them, e.g.:

    [  FAILED  ] C:/projects/neovim/test/functional\core\main_spec.lua @ 97: Command-line option -s errors out when trying to use nonexistent file with -s
    C:/projects/neovim/test/functional\core\main_spec.lua:98: Expected objects to be the same.
    Passed in:
    (string) 'Cannot open for reading: "Xtest-functional-core-main-s.nonexistent": no such file or directory
    profiling:C:\projects\neovim\build/src/nvim/CMakeFiles/nvim.dir/buffer.c.gcda:Data file mismatch - some data files may have been concurrently updated without locking support
    '
    Expected:
    (string) 'Cannot open for reading: "Xtest-functional-core-main-s.nonexistent": no such file or directory
    '

    stack traceback:
            C:/projects/neovim/test/functional\core\main_spec.lua:98: in function <C:/projects/neovim/test/functional\core\main_spec.lua:97>

For reference, the locking appears to have been reworked for gcc 9.1 [1].

1: https://github.com/gcc-mirror/gcc/commit/56621355b

helpers.clear: keep GCOV_ERROR_FILE in environment

* ci: AppVeyor: remove MINGW_64 config (used with cov now)

Also:

- run MINGW_64-gcov first, and with PRs, since it provides coverage.
2019-06-14 13:39:57 +02:00
Justin M. Keyes
fdbb5a8f72
Merge #10208 from janlazo/vim-8.0.0931
vim-patch:8.0.{931,933,953}
2019-06-14 04:38:41 -07:00
Jan Edmund Lazo
18b031ea1d vim-patch:8.0.0953: get "no write since last change" error in terminal window
Problem:    Get "no write since last change" error in terminal window.
Solution:   Use another message when closing a terminal window. Make ":quit!"
            also end the job.
f5be7cd016
2019-06-13 22:40:12 -04:00
Jan Edmund Lazo
6efa3bff09 test/old: pass Test_statusline on Windows 2019-06-13 19:39:55 -04:00
Jan Edmund Lazo
47a5456670 vim-patch:8.0.0933: terminal test tries to start GUI when it's not possible
Problem:    Terminal test tries to start GUI when it's not possible.
Solution:   Check if the GUI can run. (James McCoy, closes vim/vim#1971)
9f0139a2a8
2019-06-13 19:39:55 -04:00