As mentioned in the discussion about the popup menu fix, it's not so easy to write a test to check that something shows up in the right place, with the right highlighting, etc. Basically, that Vim displayes the right text. And when the check fails, it's not so easy to figure out what changed.
If have just submitted patch 8.0.1523, which adds functionality to work with terminal screen dumps. The idea is to write a test that puts Vim in a certain state, create a screen dump with term_dumpwrite() and check that it is equal to a reference screen dump. I added assert_equalfile() to make it easier to check if two files are equal. This should also make it a lot easier to check syntax highlighting: Load text for the language, enable syntax highlighting and create a screen dump. Any differences in highlighting from a reference dump will be easily found. If there is a difference, you can use term_dumpdiff() to find out where it is. It shows the text that is different, and pressing "s" swaps between the two versions, so you can see the context of the change. You can use term_dumpload() to view a screen dump. I haven't yet had time to actually write a test with this, thus things might still change. And it probably breaks in some cases. I also need to write an explanation of how to use this properly. It's not going to replace the existing tests. To use it in a portable way the size of the dump needs to be limited. Let me know what you think. -- My girlfriend told me I should be more affectionate. So I got TWO girlfriends. /// Bram Moolenaar -- b...@moolenaar.net -- http://www.Moolenaar.net \\\ /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ \\\ an exciting new programming language -- http://www.Zimbu.org /// \\\ help me help AIDS victims -- http://ICCF-Holland.org /// -- -- You received this message from the "vim_dev" maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php --- You received this message because you are subscribed to the Google Groups "vim_dev" group. To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.