@@ -1338,6 +1338,25 @@ func Test_prop_func_invalid_args()
13381338 call assert_fails (" call prop_type_get([])" , ' E730:' )
13391339 call assert_fails (" call prop_type_get('', [])" , ' E474:' )
13401340 call assert_fails (" call prop_type_list([])" , ' E715:' )
1341+ call assert_fails (" call prop_type_add('yyy', 'not_a_dict')" , ' E715:' )
1342+ call assert_fails (" call prop_add(1, 5, {'type':'missing_type', 'length':1})" , ' E971:' )
1343+ call assert_fails (" call prop_add(1, 5, {'type': ''})" , ' E971:' )
1344+ call assert_fails (' call prop_add(1, 1, 0)' , ' E715:' )
1345+
1346+ new
1347+ call setline (1 , [' first' , ' second' ])
1348+ call prop_type_add (' xxx' , {})
1349+
1350+ call assert_fails (" call prop_type_add('xxx', {})" , ' E969:' )
1351+ call assert_fails (" call prop_add(2, 0, {'type': 'xxx'})" , ' E964:' )
1352+ call assert_fails (" call prop_add(2, 3, {'type': 'xxx', 'end_lnum':1})" , ' E475:' )
1353+ call assert_fails (" call prop_add(2, 3, {'type': 'xxx', 'end_lnum':3})" , ' E966:' )
1354+ call assert_fails (" call prop_add(2, 3, {'type': 'xxx', 'length':-1})" , ' E475:' )
1355+ call assert_fails (" call prop_add(2, 3, {'type': 'xxx', 'end_col':0})" , ' E475:' )
1356+ call assert_fails (" call prop_add(2, 3, {'length':1})" , ' E965:' )
1357+
1358+ call prop_type_delete (' xxx' )
1359+ bwipe!
13411360endfunc
13421361
13431362func Test_prop_split_join ()
0 commit comments