Commit Graph

141 Commits

Author SHA1 Message Date
Ryan Prichard
6360ec6a5b Add test case demonstrating a Win10 15048 ReadConsoleOutput bug 2017-03-16 20:57:35 -05:00
Ryan Prichard
bf98ff3c20 Add a test program that dumps console input via _getch. 2017-01-31 22:03:52 -06:00
Ryan Prichard
4a2ff5da03 Add new test programs: ConinMode, ConoutMode, WriteConsole 2016-08-13 22:12:18 -05:00
Ryan Prichard
a0e3f337c0 Add a misc/IdentifyConsoleWindow.ps1 test script
It determines:
 - whether the program has a console
 - whether that console has a window
 - whether that window is on the current window station

It's motivated by the IntelliJ clipboard/winpty bug.
2016-06-20 00:15:53 -05:00
Ryan Prichard
ac5d8e95e7 GetConsolePos: also print the cursor position 2016-06-10 01:15:22 -05:00
Ryan Prichard
fa6ba9c725 Windows 10 new console: try to avoid freezing the console while scraping
Fixes https://github.com/rprichard/winpty/issues/53
2016-06-09 02:34:17 -05:00
Ryan Prichard
ec4558e0ec Add a test result from Win10/10586 regarding the JP locale + 437 codepage 2016-06-07 00:08:15 -07:00
Ryan Prichard
54d599d4ab Update notes -- correct a typo and comment on the 14342 bug with wmic.exe. 2016-06-06 22:27:35 -07:00
Ryan Prichard
33fae530ec Add notes about SetCurrentConsoleFontEx. 2016-06-05 23:04:33 -07:00
Ryan Prichard
661094b401 Add font information from various OS versions 2016-06-05 22:01:37 -07:00
Ryan Prichard
8bb13c6849 FontSurvey: automatically classify HHFFFF=GOOD and HHHFFF=OK 2016-06-05 19:23:26 -07:00
Ryan Prichard
111d0c67b1 Add a FontSurvey program for automatically testing 100 font sizes 2016-06-05 19:07:03 -07:00
Ryan Prichard
f7545a8499 Enhancements to misc/SetFont test program 2016-06-05 17:36:23 -07:00
Ryan Prichard
bdf3e0ec4c misc/Utf16Echo: Suppress some warnings 2016-06-05 17:05:41 -07:00
Ryan Prichard
33c5687d4a More updates to test programs for font/resizing work 2016-06-05 01:47:05 -05:00
Ryan Prichard
ebefb91e80 Update test programs for font/resizing work
* Rename QueryFont.exe to GetFont.exe -- it's shorted.  Make font table
   output shorter.  Make the program work on XP.

 * Add IsNewConsole.exe

 * Add GetBufferInfo.exe

 * Clear the executable bit on some .cc files
2016-06-04 21:10:19 -05:00
Ryan Prichard
52abfbb908 Add misc/MoveConsoleWindow test program 2016-06-04 02:48:11 -05:00
Ryan Prichard
3854d04282 Add misc/SetBufferSize.exe and misc/SetWindowRect.exe test programs 2016-06-04 02:35:03 -05:00
Ryan Prichard
0f6de50111 Get a bunch of misc test programs compiling again 2016-06-03 22:17:37 -05:00
Ryan Prichard
bd58e14b17 Check in a forgotten file: misc/EnableExtendedFlags.txt 2016-06-01 19:48:11 -05:00
Ryan Prichard
cf39c31ff6 Create a PowerShell script for controlling the console input mode. 2016-05-30 02:18:13 -05:00
Ryan Prichard
d1b9522444 Get misc/SetCursorPos.exe compiling again 2016-05-27 20:19:49 -05:00
Ryan Prichard
5a65fdc11c Use more sensible executable flags for source files
My motivation at the moment is that I'm trying to share a
git checkout between multiple VMs using VirtualBox's Shared
Folders feature.  git in the guest VM isn't able to see the
executable bits from the host due to the VirtualBox/SMB/CIFS
layer.  Instead, it thinks text files are non-executable,
unless they have a shebang line.  That's a sensible way to
set the flags anyway, so set them like that.

With this commit, there's still one file that isn't handled:
src/shared/GetCommitHash.cmd.  It's still marked executable,
but it lacks a shebang line, so the guest thinks it's
non-executable.  I'm not sure it should be changed.
2016-04-20 21:44:44 -07:00
Ryan Prichard
2e661f15fd Add a test case exploring freeze behavior on an inactive console buffer
So far, I've only tested it on Windows 7.  The test passed on that OS:
creating a screen buffer isn't blocked by selection, but writing to an
inactive buffer *is* blocked, regardless of whether the buffer was created
before or after selection began.  The use of Mark or SelectAll doesn't
affect behavior.
2016-04-19 15:00:39 -07:00
Ryan Prichard
a4ba2420e7 Split out misc/{buffer-tests,console-handles.md} to a new repo
See https://github.com/rprichard/win32-console-docs
2016-02-24 20:44:58 -06:00
Ryan Prichard
e235706503 Rename font-notes: this file isn't really Markdown. 2016-02-24 19:54:09 -06:00
Ryan Prichard
d72f4a44f8 Get many misc test programs compiling again after the src reorg 2016-01-15 03:08:10 -06:00
Ryan Prichard
05a01ab4b5 Add mouse input notes 2015-12-16 06:22:25 -06:00
Ryan Prichard
3ad4dc4530 Clarification about the wow64dup bug 2015-12-15 21:01:49 -06:00
Ryan Prichard
c2ffc0c4a6 Fix a typo: There is no Windows 7 SP2; I actually tested Windows 7 SP1. 2015-12-15 19:55:25 -06:00
Ryan Prichard
48b0ec1425 Fix a typo: There is no Windows 7 SP2; I actually tested Windows 7 SP1. 2015-12-15 19:46:29 -06:00
Ryan Prichard
7814da4dd3 Miscellaneous edits to console-handles.md. 2015-12-15 19:14:10 -06:00
Ryan Prichard
6f2a481b6b Add a table of contents to console-handles.md. 2015-12-15 18:54:01 -06:00
Ryan Prichard
95aff6bc69 Move source files into a src subdirectory.
Fixes https://github.com/rprichard/winpty/issues/51
2015-11-29 03:50:06 -06:00
Ryan Prichard
df6b9b1f60 Move Notes.txt into the misc subdirectory 2015-11-29 03:33:38 -06:00
Ryan Prichard
52b11bfba9 Convert the makefiles from recursive to non-recursive
* This change reduces the total build time from about 14 seconds to about
   9 seconds on my computer.

Also:

 * Consolidate all the intermediate files into the build directory to
   reduces clutter.

 * Allow specifying UNIX_ADAPTER_EXE to make.  Perhaps this will be helpful
   to the MSYS2 fork, which renames console.exe to winpty.exe.  (I like
   the renaming, but I don't know about the other winpty users.  Maybe
   I'll make the change after I've put out another stable release...)

 * Rename the WINPTY define to COMPILING_WINPTY_DLL define.  The longer
   name is clearer.  I define the macro inside libwinpty/winpty.cc, so the
   build system no longer needs to.  (I removed the define from
   winpty.gyp.)

 * Consolidate config-unix.mk and config-mingw.mk into config.mk.  The
   separation was previously necessary because each file had a conflicting
   definition of CXX.

 * Rename the UNIX_LDFLAGS_STATIC_LIBSTDCXX macro to UNIX_LDFLAGS_STATIC,
   because libstdc++ isn't the only thing I'm linking statically.
2015-11-06 22:08:24 -06:00
Ryan Prichard
5fb236d70e Improve the SelectAllTest a little 2015-11-06 01:00:26 -06:00
Ryan Prichard
2e24ecdcd2 Remove TestHandleInheritance, which is obsoleted by HandleTests. 2015-11-06 00:44:21 -06:00
Ryan Prichard
0d4c175037 Expand the modern console I/O tests 2015-11-06 00:30:35 -06:00
Ryan Prichard
d3198232ce Also verify that Detached->Detached CreateProcess sets NULL stdhandles. 2015-11-05 02:15:11 -06:00
Ryan Prichard
fb0940b6da Add intro material to document 2015-10-27 13:34:42 -05:00
Ryan Prichard
18941a60c2 Update duplication tests for WOW64, XP inheritability bug 2015-10-27 13:34:42 -05:00
Ryan Prichard
c9a5f624be misc/buffer-tests: Add test failure reporting 2015-10-27 13:23:18 -05:00
Ryan Prichard
7c12d90086 Get the tests running inside the WOW64 environment on pre-Win7 OSs
Prior to Windows 7, the undocumented NtQuerySystemInformation API did
not return valid handle information when called by a WOW64 process.  To
work around this problem, the 32-bit test program connects to a 64-bit
worker and uses the existing RPC mechanism, issuing LookupKernelObject
commands, which call NtQuerySystemInformation in a native 64-bit
environment.

Even on Windows 7, the NtQuerySystemInformation API returns truncated
kernel object pointers, so, AFAIK, we still need to do this work. Maybe
not, though, if the lower 32 bits are guaranteed to be unique.

On Windows 10, there is a CompareObjectHandles API that works in WOW64
mode.
2015-10-27 13:19:42 -05:00
Ryan Prichard
72c5ea52fd Fixes and comments to Test_CreateProcess_Duplicate_PseudoHandleBug
It seems that this bug was fixed in WOW64 prior to its fixing in the
normal environment.

It makes no sense to run Test_CreateProcess_Duplicate_PseudoHandleBug_IL
on OS's that don't have inherit lists.
2015-10-26 18:42:06 -05:00
Ryan Prichard
b95da0a6d8 Document my theory for the CONOUT$ Win7 bug and add a safe-ish? testcase. 2015-10-26 17:39:04 -05:00
Ryan Prichard
116f3402ba Make the Windows 7 note a bit clearer. 2015-10-26 13:09:08 -05:00
Ryan Prichard
a7feca65a7 Consolidate InheritList tests, expand them, document the semantics.
Provide a way to test for UpdateProcThreadAttribute failures, because
trying to create an empty inherit list seems interesting to me.
2015-10-26 11:53:39 -05:00
Ryan Prichard
29b9ebbc2e Add Test_AttachConsole_AllocConsole_StdHandles trad + modern tests. 2015-10-26 01:14:23 -05:00
Ryan Prichard
4a67a2073e Suppress tests; XP doesn't have inherit lists 2015-10-25 23:38:51 -05:00