]> git.feebdaed.xyz Git - 0xmirror/vim.git/commitdiff
patch 9.1.1990: tests: Test_term_gettty() fails when using conpty on Windows
authorMuraoka Taro <koron.kaoriya@gmail.com>
Wed, 17 Dec 2025 19:52:32 +0000 (20:52 +0100)
committerChristian Brabandt <cb@256bit.org>
Wed, 17 Dec 2025 19:52:32 +0000 (20:52 +0100)
Problem:  tests: Test_term_gettty() fails when using conpty on Windows,
          CI uses winpty, so this test passes.
Solution: Skip the test Test_term_gettty(). Since conpty communicates
          via anonymous pipes, there is no name that can be obtained
          with term_gettty() (Muraoka Taro)

closes: #18954

Signed-off-by: Muraoka Taro <koron.kaoriya@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
src/testdir/test_vim9_builtin.vim
src/version.c

index e66a33b6e98f5a7fb5a5a3094fca71d1748cfd3f..a07ba8c099bcf6d8e04b337ce5ec43aa0c0793cb 100644 (file)
@@ -4766,6 +4766,9 @@ def Test_term_gettty()
     CheckFeature terminal
   else
     var buf = g:Run_shell_in_terminal({})
+    if has('win32') && buf->term_getjob()->job_info()['tty_type'] == 'conpty'
+      throw 'Skipped: When using conpty, term_gettty() always returns an empty string.'
+    endif
     term_gettty(buf, true)->assert_notequal('')
     g:StopShellInTerminal(buf)
   endif
index 1b406f8922c33e8297ed0403d203c0d73e507b14..a368907018adc378cd6d25771e3536702316b345 100644 (file)
@@ -734,6 +734,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    1990,
 /**/
     1989,
 /**/