Justin M. Keyes
aa2c439940
eval.c: rename capture() to execute() ( #5132 )
2016-07-31 13:23:29 -04:00
Björn Linse
5c754a2d22
timers: make repeat=0 work one-shot (consistent with vim)
2016-06-29 18:57:18 +02:00
Björn Linse
2c39e0b03f
timers: make timers work with zero timeout
2016-06-29 18:57:18 +02:00
Björn Linse
e8a8342132
test: fix command_count_spec
...
The test hit wait_return if x or .x.swp exists in the project root directory.
2016-06-23 16:54:19 +02:00
Justin M. Keyes
8a4e5b4bc2
Merge #4697 'capture() function'.
2016-06-20 00:55:41 -04:00
ZyX
ff470bb853
functests: Check logs in lua code
...
It is otherwise impossible to determine which test failed sanitizer/valgrind
check. test/functional/helpers.lua module return was changed so that tests which
do not provide after_each function to get new check will automatically fail.
2016-06-10 21:50:49 +03:00
Shougo Matsushita
41c0dfd545
Port capture() function
...
https://groups.google.com/forum/#!msg/vim_dev/H3Z3ChSUh_4/beZs6KzYdBsJ
2016-05-27 10:33:44 +09:00
Björn Linse
5cc87d4dab
cmdline: Redraw the cmdline after processing events
...
vim-patch:7.4.1603
TODO(bfredl): if we allow events in HITRETURN and ASKMORE states,
we need to add the necessary redraws as well.
2016-05-24 22:11:37 +02:00
Björn Linse
61e8adb25e
eval: implement timers. vim-patch: 7.4.1578, 7.4.1831
...
For the moment, timers are triggered during sleep,
but not in wait-for-input modes, like press-RETURN or f_getchar()
2016-05-24 22:08:56 +02:00
KillTheMule
65b7499872
vim-patch:cb00f03
...
Add missing test file.
cb00f03933
Converted to a lua test. Change the tolerance of the test to avoid false
positives on travis.
2016-05-08 20:15:07 +02:00
KillTheMule
360d0513d1
Satisfy testlint.
...
For that, make luatest ignore the preload.lua files.
2016-04-28 19:30:17 +02:00
ZyX
a64114eba0
functests: Make json_functions_spec use new NIL where appropriate
2016-04-18 02:48:20 +03:00
ZyX
bda0165514
eval/encode: Make sure that encoder can encode NULL variables
...
Adds two undocumented v: variables: _null_list and _null_dict because I do not
know a reproducible way to get such lists (though I think I heard about this)
and dictionaries (do not remember hearing about them). NULL strings are obtained
using $XXX_UNEXISTENT_VAR_XXX.
Fixes crash in json_encode($XXX_UNEXISTENT_VAR_XXX). Other added tests worked
fine before this commit.
2016-04-18 02:48:20 +03:00
ZyX
3e435df42c
functests: Replace \xXX escapes with \DDD in lua code
2016-04-18 02:48:20 +03:00
ZyX
fd92e648ac
eval/encode: Dump FF character correctly
2016-04-18 02:48:20 +03:00
ZyX
9af400f979
eval: Treat [] and [""] as any other empty string
2016-04-18 02:48:20 +03:00
ZyX
af7ff808c7
eval: Fix overflow in error message in f_json_decode
2016-04-18 02:48:20 +03:00
ZyX
4f8b686435
documentation,functests: State that UTF-8-only support is intentional
2016-04-18 02:48:20 +03:00
ZyX
c129f6cfaf
eval/decode: Accept \r
as space character
2016-04-18 02:48:20 +03:00
ZyX
515fea1ef0
eval/decode: Reject even more numbers
...
Rejects leading zeroes and numbers like 1.e+5 (decimal dot with missing number
with signed exponent).
2016-04-18 02:48:20 +03:00
ZyX
9c543f2e24
eval/decode: Reject more numbers, accept 1e5
2016-04-18 02:48:20 +03:00
ZyX
032ac502ff
eval/decode: Do not loose high surrogates followed by high surrogates
2016-04-18 02:48:20 +03:00
ZyX
eb806c9620
eval/decode: Make sure that error messages do not cause overflow
2016-04-18 02:48:20 +03:00
ZyX
224d7df630
eval/decode: Make sure that blank input does not crash Neovim
2016-04-18 02:48:20 +03:00
ZyX
394830631f
eval/decode: Make sure that U+00C3 is parsed correctly
2016-04-18 02:48:20 +03:00
ZyX
b725f6b428
functests: Make sure that json functions are tested with C messages
2016-04-18 02:48:20 +03:00
ZyX
4a29995fe7
eval/decode: Rename brackets in error messages
...
U+007D is officially RIGHT CURLY BRACKET.
U+005D is officially RIGHT SQUARE BRACKET.
2016-04-18 02:48:20 +03:00
ZyX
942e0b338c
encode: Handle incomplete surrogates like \uSURR\uOTHR
properly
2016-04-18 02:48:20 +03:00
ZyX
406562ac6d
encode: Fail to dump NaN and infinity
...
Thanks to vim/vim#654
2016-04-18 02:48:20 +03:00
ZyX
2f67786796
eval: Rename json* functions to json_*
2016-04-18 02:48:20 +03:00
ZyX
f0bd4a1494
eval/encode: Fix invalid UTF-8 strings handling:
...
1. Do not allow reading past buffer end when creating error messages.
2. Fix surrogate pairs range, avoid magic constants.
2016-04-18 02:47:13 +03:00
ZyX
569e404622
eval/encode: Fix non-utf-8 &encoding handling, add tests
2016-04-18 02:46:34 +03:00
ZyX
0aa3e7b7ce
eval: Port parts of 7.4.1267 that are not already present
2016-04-18 02:46:34 +03:00
ZyX
b7cb8f0597
eval: Make assert_true and assert_false accept v:true and v:false
2016-04-18 02:45:49 +03:00
ZyX
6167ce6df2
eval: Remove v:none
...
To get v:none back just rever this commit. This will not make json*() functions
compatible with Vim though.
2016-04-18 02:45:49 +03:00
ZyX
e303ea8a19
eval/decode: Add support for special maps
...
Special dictionaries representing map are created when encountering duplicate
key or when key is empty or contains NUL.
Also checks that values are separated by a comma/colon properly.
2016-04-18 02:45:49 +03:00
ZyX
2c378fdfaf
eval/decode: Parse strings with NUL to special dictionaries
2016-04-18 02:45:49 +03:00
ZyX
5814e29cdb
eval/decode: Fix surrogate pairs processing
2016-04-18 02:45:49 +03:00
ZyX
ea82270d30
eval/decode: Fail on control and invalid unicode characters
2016-04-18 02:45:49 +03:00
ZyX
cddd7d47c3
eval/decode: Make msgpackparse() function use new v: vars
2016-04-18 02:45:49 +03:00
ZyX
e213ba1506
eval: Add jsondecode() function
2016-04-18 02:45:49 +03:00
ZyX
f5c35ba109
functests/msgpack: Test dumping special nil and bool dicts
2016-04-18 02:44:03 +03:00
ZyX
d70a322c40
eval: Add special variables v:false, v:null, v:none
2016-04-18 02:44:03 +03:00
ZyX
18903bd9b8
eval: Add special variable type
2016-04-18 02:44:03 +03:00
ZyX
68e58444b4
eval: Add jsonencode() function
...
Ref #3471
2016-04-18 02:44:03 +03:00
ZyX
c3efad5398
functests(msgpack): Fix location of one of the tests
2016-04-18 02:44:03 +03:00
ZyX
f21cb425fb
functests(msgpack): Fix test names
2016-04-18 02:44:03 +03:00
Justin M. Keyes
54188cddde
test: move server_spec.lua
...
Old layout was too granular, we do not need a server/ folder.
2016-04-15 02:23:27 -04:00
Björn Linse
7ab9ff88e6
eval: add v:event, which will contain data events want to propagate to their receivers.
...
Add helper functions dict_clear and dict_set_keys_readonly.
2016-02-29 16:06:41 +01:00
ZyX
610b48c5b0
functests: Add string() function tests
2016-02-02 00:54:00 +03:00