patch 8.2.3281: Vim9: TODO items in tests can be taken care of
Problem: Vim9: TODO items in tests can be taken care of.
Solution: Update test for now working functionality. (closes #8694)
diff --git a/src/testdir/test_vim9_assign.vim b/src/testdir/test_vim9_assign.vim
index fa26548..428de1c 100644
--- a/src/testdir/test_vim9_assign.vim
+++ b/src/testdir/test_vim9_assign.vim
@@ -1228,23 +1228,11 @@
d.somekey = 'someval'
assert_equal({key: 'value', '123': 'qwerty', somekey: 'someval'}, d)
- # unlet d.somekey
- # assert_equal({key: 'value', '123': 'qwerty'}, d)
+ unlet d.somekey
+ assert_equal({key: 'value', '123': 'qwerty'}, d)
END
CheckDefAndScriptSuccess(lines)
- # TODO: move to above once "unlet d.somekey" in :def is implemented
- lines =<< trim END
- vim9script
- var d: dict<string> = {}
- d['key'] = 'value'
- d.somekey = 'someval'
- assert_equal({key: 'value', somekey: 'someval'}, d)
- unlet d.somekey
- assert_equal({key: 'value'}, d)
- END
- CheckScriptSuccess(lines)
-
CheckDefFailure(["var d: dict<number> = {a: '', b: true}"], 'E1012: Type mismatch; expected dict<number> but got dict<any>', 1)
CheckDefFailure(["var d: dict<dict<number>> = {x: {a: '', b: true}}"], 'E1012: Type mismatch; expected dict<dict<number>> but got dict<dict<any>>', 1)
enddef