aboutsummaryrefslogtreecommitdiff
path: root/test/unit
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2022-10-26 20:10:41 +0800
committerzeertzjq <zeertzjq@outlook.com>2022-10-26 20:53:39 +0800
commit46a54dd6a03f51ba08142abe0aa5710705917987 (patch)
tree6b88d5ab645201a103cad3a67a98eadb07e6e5b4 /test/unit
parentef363ed37cdf5c460cca840aebc825011e0294ee (diff)
downloadrneovim-46a54dd6a03f51ba08142abe0aa5710705917987.tar.gz
rneovim-46a54dd6a03f51ba08142abe0aa5710705917987.tar.bz2
rneovim-46a54dd6a03f51ba08142abe0aa5710705917987.zip
vim-patch:8.2.1852: map() returing zero for NULL list is unexpected
Problem: map() returing zero for NULL list is unexpected. Solution: Return the empty list. (closes vim/vim#7133) https://github.com/vim/vim/commit/ffdf8adfa8108d4765fdc68abbd2fe49a4292b25 Co-authored-by: Bram Moolenaar <Bram@vim.org>
Diffstat (limited to 'test/unit')
-rw-r--r--test/unit/eval/typval_spec.lua8
1 files changed, 4 insertions, 4 deletions
diff --git a/test/unit/eval/typval_spec.lua b/test/unit/eval/typval_spec.lua
index 6387f89fe4..34dbf592a5 100644
--- a/test/unit/eval/typval_spec.lua
+++ b/test/unit/eval/typval_spec.lua
@@ -2253,8 +2253,8 @@ describe('typval.c', function()
local d1 = dict()
alloc_log:check({a.dict(d1)})
eq(1, d1.dv_refcount)
- eq(false, tv_dict_equal(nil, d1))
- eq(false, tv_dict_equal(d1, nil))
+ eq(true, tv_dict_equal(nil, d1))
+ eq(true, tv_dict_equal(d1, nil))
eq(true, tv_dict_equal(d1, d1))
eq(1, d1.dv_refcount)
alloc_log:check({})
@@ -2721,8 +2721,8 @@ describe('typval.c', function()
local d1 = lua2typvalt({})
alloc_log:check({a.dict(d1.vval.v_dict)})
eq(1, d1.vval.v_dict.dv_refcount)
- eq(false, tv_equal(nd, d1))
- eq(false, tv_equal(d1, nd))
+ eq(true, tv_equal(nd, d1))
+ eq(true, tv_equal(d1, nd))
eq(true, tv_equal(d1, d1))
eq(1, d1.vval.v_dict.dv_refcount)
alloc_log:check({})