Mercurial > vim
annotate src/testdir/test_vim9_fails.vim @ 28994:644b0f0541de v8.2.5019
patch 8.2.5019: cannot get the first screen column of a character
Commit: https://github.com/vim/vim/commit/0f7a3e1de6f71e8e1423fe594890d6aa7f94e132
Author: LemonBoy <thatlemon@gmail.com>
Date: Thu May 26 12:10:37 2022 +0100
patch 8.2.5019: cannot get the first screen column of a character
Problem: Cannot get the first screen column of a character.
Solution: Let virtcol() optionally return a list. (closes https://github.com/vim/vim/issues/10482,
closes #7964)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Thu, 26 May 2022 13:15:04 +0200 |
parents | b94ef0b282f1 |
children | 54e36d01847b |
rev | line source |
---|---|
22582
a3df1fb28d44
patch 8.2.1839: Vim9: memory leaks reported in assign test
Bram Moolenaar <Bram@vim.org>
parents:
diff
changeset
|
1 " Test for Vim9 script with failures, causing memory leaks to be reported. |
a3df1fb28d44
patch 8.2.1839: Vim9: memory leaks reported in assign test
Bram Moolenaar <Bram@vim.org>
parents:
diff
changeset
|
2 " The leaks happen after a fork() and can be ignored. |
a3df1fb28d44
patch 8.2.1839: Vim9: memory leaks reported in assign test
Bram Moolenaar <Bram@vim.org>
parents:
diff
changeset
|
3 |
26410
b94ef0b282f1
patch 8.2.3736: test fails without the channel feature
Bram Moolenaar <Bram@vim.org>
parents:
26368
diff
changeset
|
4 source check.vim |
b94ef0b282f1
patch 8.2.3736: test fails without the channel feature
Bram Moolenaar <Bram@vim.org>
parents:
26368
diff
changeset
|
5 |
22582
a3df1fb28d44
patch 8.2.1839: Vim9: memory leaks reported in assign test
Bram Moolenaar <Bram@vim.org>
parents:
diff
changeset
|
6 def Test_assignment() |
26410
b94ef0b282f1
patch 8.2.3736: test fails without the channel feature
Bram Moolenaar <Bram@vim.org>
parents:
26368
diff
changeset
|
7 if !has('channel') |
b94ef0b282f1
patch 8.2.3736: test fails without the channel feature
Bram Moolenaar <Bram@vim.org>
parents:
26368
diff
changeset
|
8 CheckFeature channel |
b94ef0b282f1
patch 8.2.3736: test fails without the channel feature
Bram Moolenaar <Bram@vim.org>
parents:
26368
diff
changeset
|
9 else |
22582
a3df1fb28d44
patch 8.2.1839: Vim9: memory leaks reported in assign test
Bram Moolenaar <Bram@vim.org>
parents:
diff
changeset
|
10 var chan1: channel |
a3df1fb28d44
patch 8.2.1839: Vim9: memory leaks reported in assign test
Bram Moolenaar <Bram@vim.org>
parents:
diff
changeset
|
11 var job1: job |
a3df1fb28d44
patch 8.2.1839: Vim9: memory leaks reported in assign test
Bram Moolenaar <Bram@vim.org>
parents:
diff
changeset
|
12 var job2: job = job_start('willfail') |
a3df1fb28d44
patch 8.2.1839: Vim9: memory leaks reported in assign test
Bram Moolenaar <Bram@vim.org>
parents:
diff
changeset
|
13 endif |
a3df1fb28d44
patch 8.2.1839: Vim9: memory leaks reported in assign test
Bram Moolenaar <Bram@vim.org>
parents:
diff
changeset
|
14 enddef |
26368
744fdb15347d
patch 8.2.3715: Vim9: valgrind reports spurious problems for a test
Bram Moolenaar <Bram@vim.org>
parents:
22582
diff
changeset
|
15 |
744fdb15347d
patch 8.2.3715: Vim9: valgrind reports spurious problems for a test
Bram Moolenaar <Bram@vim.org>
parents:
22582
diff
changeset
|
16 " Unclear why this test causes valgrind to report problems. |
744fdb15347d
patch 8.2.3715: Vim9: valgrind reports spurious problems for a test
Bram Moolenaar <Bram@vim.org>
parents:
22582
diff
changeset
|
17 def Test_job_info_return_type() |
744fdb15347d
patch 8.2.3715: Vim9: valgrind reports spurious problems for a test
Bram Moolenaar <Bram@vim.org>
parents:
22582
diff
changeset
|
18 if !has('job') |
744fdb15347d
patch 8.2.3715: Vim9: valgrind reports spurious problems for a test
Bram Moolenaar <Bram@vim.org>
parents:
22582
diff
changeset
|
19 CheckFeature job |
744fdb15347d
patch 8.2.3715: Vim9: valgrind reports spurious problems for a test
Bram Moolenaar <Bram@vim.org>
parents:
22582
diff
changeset
|
20 else |
744fdb15347d
patch 8.2.3715: Vim9: valgrind reports spurious problems for a test
Bram Moolenaar <Bram@vim.org>
parents:
22582
diff
changeset
|
21 var job: job = job_start(&shell) |
744fdb15347d
patch 8.2.3715: Vim9: valgrind reports spurious problems for a test
Bram Moolenaar <Bram@vim.org>
parents:
22582
diff
changeset
|
22 var jobs = job_info() |
744fdb15347d
patch 8.2.3715: Vim9: valgrind reports spurious problems for a test
Bram Moolenaar <Bram@vim.org>
parents:
22582
diff
changeset
|
23 assert_equal('list<job>', typename(jobs)) |
744fdb15347d
patch 8.2.3715: Vim9: valgrind reports spurious problems for a test
Bram Moolenaar <Bram@vim.org>
parents:
22582
diff
changeset
|
24 assert_equal('dict<any>', typename(job_info(jobs[0]))) |
744fdb15347d
patch 8.2.3715: Vim9: valgrind reports spurious problems for a test
Bram Moolenaar <Bram@vim.org>
parents:
22582
diff
changeset
|
25 job_stop(job) |
744fdb15347d
patch 8.2.3715: Vim9: valgrind reports spurious problems for a test
Bram Moolenaar <Bram@vim.org>
parents:
22582
diff
changeset
|
26 endif |
744fdb15347d
patch 8.2.3715: Vim9: valgrind reports spurious problems for a test
Bram Moolenaar <Bram@vim.org>
parents:
22582
diff
changeset
|
27 enddef |
744fdb15347d
patch 8.2.3715: Vim9: valgrind reports spurious problems for a test
Bram Moolenaar <Bram@vim.org>
parents:
22582
diff
changeset
|
28 |