[vim/vim] Test hardcopy with 'printmbcharset' to improve coverage (#5783)

6 views
Skip to first unread message

Dominique Pellé

unread,
Mar 15, 2020, 6:54:09 AM3/15/20
to vim/vim, Subscribed

This PR improves test coverage of :hardcopy by
testing with 'printmbcharset'.

It also speeds up test Test_printoptions() by limiting the range
of lines to print.


You can view, comment on, or merge this pull request online at:

  https://github.com/vim/vim/pull/5783

Commit Summary

  • Test hardcopy with 'printmbcharset' to improve coverage

File Changes

Patch Links:


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or unsubscribe.

Dominique Pellé

unread,
Mar 15, 2020, 7:52:22 AM3/15/20
to vim/vim, Push

@dpelle pushed 1 commit.

  • 92b83ce test_hardcopy was hanging in Windows CI


You are receiving this because you are subscribed to this thread.

View it on GitHub or unsubscribe.

Dominique Pellé

unread,
Mar 15, 2020, 8:26:40 AM3/15/20
to vim/vim, Subscribed

@dpelle commented on this pull request.


In src/testdir/test_hardcopy.vim:

> @@ -63,6 +63,35 @@ func Test_printmbfont()
   bwipe
 endfunc
 
+func Test_printmbcharset()
+  " FIXME: Unclear why this fails on Windows.
+  if !has('unix')
+    return
+  endif

The test was hanging on Window CI (Appveyor).
I merely disabled the new tests on Windows
as I don't have a Windows machine to reproduce it.

I'd appreciate if someone with a windows host could check
why this test is failing. File test_hardcopy.vim has several
tests disabled on Windows:

  • Test_printmbcharset()
  • Test_printexpr()
  • Test_errors()
  • Test_empty_buffer()

Yegappan Lakshmanan

unread,
Mar 15, 2020, 11:04:27 AM3/15/20
to vim_dev, reply+ACY5DGDKFN5JWWZDGE...@reply.github.com, vim/vim, Subscribed
Hi Domnique,

On Sun, Mar 15, 2020 at 5:26 AM Dominique Pellé <vim-dev...@256bit.org> wrote:

@dpelle commented on this pull request.


In src/testdir/test_hardcopy.vim:

> @@ -63,6 +63,35 @@ func Test_printmbfont()
   bwipe
 endfunc
 
+func Test_printmbcharset()
+  " FIXME: Unclear why this fails on Windows.
+  if !has('unix')
+    return
+  endif

The test was hanging on Window CI (Appveyor).
I merely disabled the new tests on Windows
as I don't have a Windows machine to reproduce it.

I'd appreciate if someone with a windows host could check
why this test is failing. File test_hardcopy.vim has several
tests disabled on Windows:

  • Test_printmbcharset()
  • Test_printexpr()
  • Test_errors()
  • Test_empty_buffer()

The tests are failing on MS-Windows because "+postscript"
is missing. The Windows binary needs to be built with
"POSTSCRIPT=yes" in Appveyor.

I tested this on a MS-Windows machine with postscript enabled
and the above tests (after removing the unix check) are passing.

BTW, you may want to add the following modeline to test_hardcopy.vim:

" vim: shiftwidth=2 sts=2 expandtab

- Yegappan

vim-dev ML

unread,
Mar 15, 2020, 11:04:45 AM3/15/20
to vim/vim, vim-dev ML, Your activity

Hi Domnique,

On Sun, Mar 15, 2020 at 5:26 AM Dominique Pellé <vim-dev...@256bit.org>
wrote:

> *@dpelle* commented on this pull request.
> ------------------------------
>
> In src/testdir/test_hardcopy.vim
> <https://github.com/vim/vim/pull/5783#discussion_r392668920>:

>
> > @@ -63,6 +63,35 @@ func Test_printmbfont()
> bwipe
> endfunc
>
> +func Test_printmbcharset()
> + " FIXME: Unclear why this fails on Windows.
> + if !has('unix')
> + return
> + endif
>
> The test was hanging on Window CI (Appveyor).
> I merely disabled the new tests on Windows
> as I don't have a Windows machine to reproduce it.
>
> I'd appreciate if someone with a windows host could check
> why this test is failing. File test_hardcopy.vim has several
> tests disabled on Windows:
>
> - Test_printmbcharset()
> - Test_printexpr()
> - Test_errors()
> - Test_empty_buffer()

>
>
The tests are failing on MS-Windows because "+postscript"
is missing. The Windows binary needs to be built with
"POSTSCRIPT=yes" in Appveyor.

I tested this on a MS-Windows machine with postscript enabled
and the above tests (after removing the unix check) are passing.

BTW, you may want to add the following modeline to test_hardcopy.vim:

" vim: shiftwidth=2 sts=2 expandtab

- Yegappan

Dominique Pellé

unread,
Mar 15, 2020, 11:47:08 AM3/15/20
to vim/vim, vim-dev ML, Push

@dpelle pushed 1 commit.

  • 9d1310b Added missing checks for 'postscript' feature


You are receiving this because you are subscribed to this thread.

Dominique Pellé

unread,
Mar 15, 2020, 12:20:10 PM3/15/20
to vim/vim, vim-dev ML, Push

@dpelle pushed 1 commit.

  • c6e1b29 Added POSTSCRIPT=yes for Windows + modeline in test_hardcopy.vim


You are receiving this because you are subscribed to this thread.

Dominique Pellé

unread,
Mar 15, 2020, 12:47:10 PM3/15/20
to vim/vim, vim-dev ML, Comment

Yegappan wrote;

The tests are failing on MS-Windows because "+postscript" is missing.

Right, thank you. I added has('postscript').
Also added POSTSCRIPT=yes for Windows and the suggested modeline.


You are receiving this because you commented.

Yegappan Lakshmanan

unread,
Mar 15, 2020, 12:53:28 PM3/15/20
to vim_dev, reply+ACY5DGCFDKTLJHFOSW...@reply.github.com, vim/vim, vim-dev ML, Comment
Hi,

On Sun, Mar 15, 2020 at 9:47 AM Dominique Pellé <vim-dev...@256bit.org> wrote:

Yegappan wrote;

The tests are failing on MS-Windows because "+postscript" is missing.

Right, thank you. I added has('postscript').
Also added POSTSCRIPT=yes for Windows and the suggested modeline.


The Travis-CI huge/clang build for your PR failed when running the
test_termcodes test. This is not related to your change. I have added
a test for bringing up the popup menu using the mouse rightclick button.
That test is failing/hanging because the popupmenu is not dismissed
for some reason. In other test runs, this test is passing.

- Yegappan

vim-dev ML

unread,
Mar 15, 2020, 12:53:50 PM3/15/20
to vim/vim, vim-dev ML, Your activity

Bram Moolenaar

unread,
Mar 15, 2020, 1:28:10 PM3/15/20
to vim/vim, vim-dev ML, Comment

Closed #5783 via 833805a.


You are receiving this because you commented.

Reply all
Reply to author
Forward
0 new messages