aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/benchmark/bench_regexp_spec.lua (renamed from test/benchmark/bench_re_freeze_spec.lua)10
-rw-r--r--test/functional/vimscript/null_spec.lua2
2 files changed, 6 insertions, 6 deletions
diff --git a/test/benchmark/bench_re_freeze_spec.lua b/test/benchmark/bench_regexp_spec.lua
index abd97f8aa8..903af5f574 100644
--- a/test/benchmark/bench_re_freeze_spec.lua
+++ b/test/benchmark/bench_regexp_spec.lua
@@ -1,4 +1,4 @@
--- Test for benchmarking RE engine.
+-- Test for benchmarking the RE engine.
local helpers = require('test.functional.helpers')(after_each)
local insert, source = helpers.insert, helpers.source
@@ -13,13 +13,13 @@ local sample_file = 'src/nvim/testdir/samples/re.freeze.txt'
local measure_cmd =
[[call Measure(%d, ']] .. sample_file .. [[', '\s\+\%%#\@<!$', '+5')]]
local measure_script = [[
- func! Measure(re, file, pattern, arg)
- let sstart=reltime()
+ func Measure(re, file, pattern, arg)
+ let sstart = reltime()
- execute 'set re=' . a:re
+ execute 'set re=' .. a:re
execute 'split' a:arg a:file
call search(a:pattern, '', '', 10000)
- q!
+ quit!
$put =printf('file: %s, re: %d, time: %s', a:file, a:re, reltimestr(reltime(sstart)))
endfunc]]
diff --git a/test/functional/vimscript/null_spec.lua b/test/functional/vimscript/null_spec.lua
index 2451da983e..1153baac46 100644
--- a/test/functional/vimscript/null_spec.lua
+++ b/test/functional/vimscript/null_spec.lua
@@ -69,7 +69,7 @@ describe('NULL', function()
null_expr_test('can be splice-indexed', 'L[:]', 0, {})
null_expr_test('is not locked', 'islocked("v:_null_list")', 0, 0)
null_test('is accepted by :for', 'for x in L|throw x|endfor', 0)
- null_expr_test('does not crash append()', 'append(1, L)', 0, 0, function()
+ null_expr_test('does not crash append()', 'append(0, L)', 0, 0, function()
eq({''}, curbufmeths.get_lines(0, -1, false))
end)
null_expr_test('does not crash setline()', 'setline(1, L)', 0, 0, function()