unittests: Move tv_dict_add* tests to a proper describe() block

This commit is contained in:
ZyX 2017-03-25 20:17:00 +03:00
parent 49195063fd
commit 4536c064e4

View File

@ -1768,7 +1768,9 @@ describe('typval.c', function()
{tv_dict_get_callback(d, 'testt', 5)})
end)
end)
describe('dict_add()', function()
end)
describe('add', function()
describe('()', function()
itp('works', function()
local di = lib.tv_dict_item_alloc_len('t-est', 5)
alloc_log:check({a.di(di, 't-est')})
@ -1789,7 +1791,7 @@ describe('typval.c', function()
'E685: Internal error: hash_add()'))
end)
end)
describe('dict_add_list()', function()
describe('list()', function()
itp('works', function()
local l = list(1, 2, 3)
alloc_log:clear()
@ -1815,7 +1817,7 @@ describe('typval.c', function()
alloc_log:check({})
end)
end)
describe('dict_add_dict()', function()
describe('dict()', function()
itp('works', function()
local d2 = dict({foo=42})
alloc_log:clear()
@ -1841,7 +1843,7 @@ describe('typval.c', function()
alloc_log:check({})
end)
end)
describe('dict_add_nr()', function()
describe('nr()', function()
itp('works', function()
local d = dict({test=10})
alloc_log:clear()
@ -1861,7 +1863,7 @@ describe('typval.c', function()
alloc_log:check({})
end)
end)
describe('dict_add_str()', function()
describe('str()', function()
itp('works', function()
local d = dict({test=10})
alloc_log:clear()