1" Test that the methods used for testing work. 2 3func Test_assert_false() 4 call assert_false(0) 5endfunc 6 7func Test_assert_true() 8 call assert_true(1) 9 call assert_true(123) 10endfunc 11 12func Test_assert_equal() 13 let s = 'foo' 14 call assert_equal('foo', s) 15 let n = 4 16 call assert_equal(4, n) 17 let l = [1, 2, 3] 18 call assert_equal([1, 2, 3], l) 19endfunc 20 21func Test_assert_exception() 22 try 23 nocommand 24 catch 25 call assert_exception('E492:') 26 endtry 27 28 try 29 nocommand 30 catch 31 try 32 " illegal argument, get NULL for error 33 call assert_exception([]) 34 catch 35 call assert_exception('E730:') 36 endtry 37 endtry 38endfunc 39 40func Test_user_is_happy() 41 smile 42 sleep 300m 43endfunc 44