From 36dfd65f6cbae16fa9599b7741f09ea29310b0af Mon Sep 17 00:00:00 2001 From: Ingo Karkat Date: Mon, 13 May 2019 11:36:12 +0200 Subject: [PATCH] Tests: Add coverage for existing ingo#dict#FromKeys() --- tests/dict/t1100-FromKeys.vim | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 tests/dict/t1100-FromKeys.vim diff --git a/tests/dict/t1100-FromKeys.vim b/tests/dict/t1100-FromKeys.vim new file mode 100644 index 0000000..e7b8b7a --- /dev/null +++ b/tests/dict/t1100-FromKeys.vim @@ -0,0 +1,9 @@ +" Test creating Dict from keys. + +call vimtest#StartTap() +call vimtap#Plan(2) + +call vimtap#Is(ingo#dict#FromKeys([], 1), {}, 'create with empty keys') +call vimtap#Is(ingo#dict#FromKeys(['foo', 'bar', 'baz'], 1), {'foo': 1, 'bar': 1, 'baz': 1}, 'create with default value 1') + +call vimtest#Quit()