Justin M. Keyes
e72ecdb7ca
test/util: expect_msg_seq()
...
job_spec.lua on AppVeyor (Windows) often fails like this:
FAILED ] C:/projects/neovim/test/functional\core\job_spec.lua @ 72: jobs changes to given `cwd` directory
C:/projects/neovim/test/functional\core\job_spec.lua:81: Expected objects to be the same.
Passed in:
(table) {
[1] = 'notification'
[2] = 'stdout'
*[3] = {
[1] = 0
*[2] = {
[1] = 'C:\projects\neovim\Xtest-tmpdir\nvimmSjq1S\0' } } }
Expected:
(table) {
[1] = 'notification'
[2] = 'stdout'
*[3] = {
[1] = 0
*[2] = {
[1] = 'C:\projects\neovim\Xtest-tmpdir\nvimmSjq1S\0'
*[2] = '' } } }
stack traceback:
Message chunking is non-deterministic, so we need to try different
variants.
2018-02-18 19:19:03 +01:00
George Zhao
499c9a1553
test/win: fix some environment assumptions #7912
...
fix #7909
fix #7910
2018-01-28 19:10:18 +01:00
Björn Linse
308dd53783
channel: check for existance before trying to set key
...
This avoids an error message in async context, where it is not safe.
2017-12-23 14:02:00 +01:00
Björn Linse
e3c4c8a90e
tests: mark flaky socket test pending for now
2017-11-27 11:43:24 +01:00
Björn Linse
91b856ccce
channels: tests
2017-11-26 09:17:04 +01:00
Justin M. Keyes
54cac3033f
test: startup_spec: cmd.exe escaping
2017-11-04 09:36:52 +01:00
Justin M. Keyes
68bef0a57d
test: has("ttyin"), has("ttyout")
2017-11-04 09:36:52 +01:00
Josh Leeb-du Toit
9db42d4ce9
:cquit : take an error code argument #7336
...
closes #2699
ex_cmds.lua: use flags consistent with similar commands such as `cnext`.
upstream discussion:
"[patch] :qcuit can take exit code"
https://groups.google.com/d/msg/vim_dev/_PjyNbUKyRc/oPgr5_ZXc6AJ
2017-10-22 13:02:31 +02:00
Justin M. Keyes
6f7754dfa0
test: avoid extra clear() calls
...
also: various other cleanup
2017-10-02 01:46:16 +02:00
Ignas Anikevicius
2b133101cf
win: vim_FullName(): force backslashes #7287
...
- Replace obvious cases of '/' literal with PATHSEP. (There are still
some remaining cases that need closer inspection.)
- Fixup tests: ui/screen_basic
closes #7117
ref https://github.com/neovim/neovim/issues/2471#issuecomment-271193714
2017-10-02 00:48:30 +02:00
Drew Neil
ac52947838
Repair job_spec functional tests
2017-08-21 20:44:03 +01:00
Justin M. Keyes
92101947fe
test: job_spec.lua: disable shada in test instance
2017-08-04 22:25:39 +02:00
ZyX
65fb622000
functests: Replace execute with either command or feed_command
...
Hope this will make people using feed_command less likely: this hides bugs.
Already found at least two:
1. msgpackparse() will show internal error: hash_add() in case of duplicate
keys, though it will still work correctly. Currently silenced.
2. ttimeoutlen was spelled incorrectly, resulting in option not being set when
expected. Test was still functioning somehow though. Currently fixed.
2017-04-09 03:24:08 +03:00
Justin M. Keyes
1ea9ebf112
test: Use workspace-local temp directory.
...
Closes #6291
2017-03-30 02:55:00 +02:00
Matthew Malcomson
f6946c68ae
job-control: set CLOEXEC on pty processes. #5986
...
Before this change, new processes started with libuv prevented SIGHUP
from reaching pty processes (by keeping the ptmx file descriptor open).
2017-03-17 12:20:51 +01:00
James McCoy
d4dd447ded
win: test: Fix closure jobs test on Windows
2017-02-23 01:24:55 -05:00
Michael Ennen
ef8701610b
Allow lambdas to be used with jobs, timers and dictwatchers.
2017-02-14 17:38:19 -07:00
Justin M. Keyes
bd16e116eb
win: test: Enable jobstart() 'shell' test. ( #5983 )
2017-01-21 17:04:39 +01:00
Justin M. Keyes
7637df4b59
win: test: XXX: Disable some tests.
2017-01-19 09:55:57 +01:00
Justin M. Keyes
32c7971b2a
win: fix warnings
2017-01-19 09:55:57 +01:00
Justin M. Keyes
e40946a5be
win: test: enable job_spec.lua
...
- Default to powershell.
- Avoid hardcoded "-c".
- Remove ^M character from received lines.
- pending_win32(): clear() is unnecessary and it pollutes the tests.
Closes #3973
Helped-by: Rui Abreu Ferreira <raf-ep@gmx.com >
2017-01-19 09:55:57 +01:00
James McCoy
bde9bedb0b
job: Consume content from rbuffer before invoking the callback again
...
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
2017-01-14 07:49:07 -05:00
Justin M. Keyes
82edcb593b
Windows: enable more tests
2017-01-13 01:17:12 +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
Justin M. Keyes
0b244de384
test: job_spec: Avoid unreliable screen test.
2016-12-23 18:28:54 +01:00
Justin M. Keyes
43ba7f4d98
eval.c: set_selfdict(): Fix invalid memory access.
2016-12-14 20:52:18 +01:00
Marco Hinz
5855f30cb1
Make VimL code compatible with merged Partial support ( #5765 )
...
Closes #5763 .
2016-12-13 14:48:42 +01:00
Michael Ennen
5e4eb18eb0
Add some tests and cleanup.
2016-12-12 10:17:35 -05:00
Björn Linse
0f681c80e1
Make partials work with jobs, timers, and dictwatchers.
2016-12-12 10:17:35 -05:00
Justin M. Keyes
d32888073f
test: jobstart()
2016-12-11 01:14:22 +01:00
Aaron Williamson
c8d5e9230e
jobstart(): Return -1 if cmd is not executable. #5671
...
Closes #5465
2016-12-10 16:01:27 +01:00
Justin M. Keyes
933c873cae
test: Handle SIGHUP in tty-test fixture.
...
Closes #5727
2016-12-07 17:22:37 +01:00
Marco Hinz
df2ffe48ce
Tests: add tests for v:exiting
2016-12-01 14:57:27 +01:00
Björn Linse
1d4563771b
jobs: ensure calling jobclose() on a pty job sends SIGHUP. Closes #5619
2016-11-17 15:13:45 +01:00
Justin M. Keyes
6636e2a259
test: :terminal should not interrupt Press-ENTER
...
References #2748
2016-10-20 23:41:59 +02:00
Justin M. Keyes
ac819b8994
CI: Travis macOS: Skip tab left-drag tests.
...
These tests fail on master, so it's not a regression. Changes in #4874
(parent commit) seem to work (and pass most CI), so skipping these tests
is better than blocking the changes.
2016-09-12 03:42:51 +02:00
Rui Abreu Ferreira
9ce81f7b2b
functionaltest: Create lua helper for os.tmpname()
...
In Windows Lua's os.tmpname() returns relative paths starting with \s,
prepend them with $TEMP to generate a valid path.
In OS X os.tmpname() returns paths in '/tmp' but they should be in
'/private/tmp'. We cannot use os_name() for platform detection because
some tests use tempname() before nvim is spawned, instead use one of the
following:
1. Set SYSTEM_NAME environment variable before calling the tests, it
is set from CMAKE_SYSTEM_NAME(i.e. uname -s or 'Windows')
2. Call uname -s
3. Assume windows
2016-08-31 11:32:28 +01:00
Rui Abreu Ferreira
39c628d031
Mark some functional tests as pending in Windows
2016-08-26 08:21:41 +01:00
Björn Linse
2d60a15e25
job control: reuse common job code for rpc jobs
...
This makes stderr and exit callbacks work for rpc jobs
2016-08-20 12:55:35 +02:00
Justin M. Keyes
68d9198501
XXX: CI: Disable hanging test on Travis OSX.
...
Temporary change to avoid frequent hangs on Travis macOS/OSX builds.
Hang does not occur on Quickbuild OSX (Yosemite) build.
Reverting e9061117a5
avoids the hang, but causes
more serious regressions on many more systems.
Note that the job_spec hang only happens with the gcc-4.9 Travis OSX build.
References #5002
References #5029
2016-08-09 15:17:46 -04:00
Justin M. Keyes
ff93c9bd90
test: PTY descendants should not prevent exit.
2016-07-16 03:34:59 -04:00