blob: 216ef0b286f853073ec1f152df9d6ae43576eda2 [file] [log] [blame]
Bram Moolenaarfc8aa6d2020-10-12 20:31:26 +02001" Test for Vim9 script with failures, causing memory leaks to be reported.
2" The leaks happen after a fork() and can be ignored.
3
4def Test_assignment()
5 if has('channel')
6 var chan1: channel
7 var job1: job
8 var job2: job = job_start('willfail')
9 endif
10enddef
Bram Moolenaarf0e496a2021-12-01 12:41:31 +000011
12" Unclear why this test causes valgrind to report problems.
13def Test_job_info_return_type()
14 if !has('job')
15 CheckFeature job
16 else
17 var job: job = job_start(&shell)
18 var jobs = job_info()
19 assert_equal('list<job>', typename(jobs))
20 assert_equal('dict<any>', typename(job_info(jobs[0])))
21 job_stop(job)
22 endif
23enddef
24