patch 8.2.0047: cannot skip tests for specific MS-Windows platform
Problem: Cannot skip tests for specific MS-Windows platform.
Solution: Add windowsversion().
diff --git a/src/testdir/gen_opt_test.vim b/src/testdir/gen_opt_test.vim
index f70623b..91415e4 100644
--- a/src/testdir/gen_opt_test.vim
+++ b/src/testdir/gen_opt_test.vim
@@ -10,6 +10,8 @@
" The terminal size is restored at the end.
" Clear out t_WS, we don't want to resize the actual terminal.
let script = [
+ \ '" DO NOT EDIT: Generated with gen_opt_test.vim',
+ \ '',
\ 'let save_columns = &columns',
\ 'let save_lines = &lines',
\ 'let save_term = &term',
@@ -123,7 +125,7 @@
\ 'printmbfont': [['', 'r:some', 'b:Bold,c:yes'], ['xxx']],
\ 'printoptions': [['', 'header:0', 'left:10pc,top:5pc'], ['xxx']],
\ 'scrollopt': [['', 'ver', 'ver,hor'], ['xxx']],
- \ 'renderoptions': [['', 'type:directx'], ['xxx']],
+ \ 'renderoptions': [[''], ['xxx']],
\ 'selection': [['old', 'inclusive'], ['', 'xxx']],
\ 'selectmode': [['', 'mouse', 'key,cmd'], ['xxx']],
\ 'sessionoptions': [['', 'blank', 'help,options,slash'], ['xxx']],
diff --git a/src/testdir/test_options.vim b/src/testdir/test_options.vim
index 65600ee..048356a 100644
--- a/src/testdir/test_options.vim
+++ b/src/testdir/test_options.vim
@@ -389,6 +389,15 @@
endif
endfunc
+func Test_renderoptions()
+ " Only do this for Windows Vista and later, fails on Windows XP and earlier.
+ " Doesn't hurt to do this on a non-Windows system.
+ if windowsversion() !~ '^[345]\.'
+ set renderoptions=type:directx
+ set rop=type:directx
+ endif
+endfunc
+
func ResetIndentexpr()
set indentexpr=
endfunc