Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is there anything like xvfb or xnest for Windows? [closed]

On projects with end-to-end tests that drive the GUI, it is awkward to run the tests on a developer workstation because the GUI automation driver interferes with the desktop. It moves the mouse, steals focus away from apps we want to use, and can start typing text into the wrong application if we switch to another app during a test run.

On Linux we've solved this by running the application under test on a virtual X server (xvfb or xnest). With xnest we can watch the tests running but still use the real desktop without interference.

Is there anything equivalent for Windows?

like image 790
Nat Avatar asked Jun 03 '09 10:06

Nat


People also ask

What is XVFB used for?

Xvfb or X virtual framebuffer is a display server implementing the X11 display server protocol. In contrast to other display servers, Xvfb performs all graphical operations in virtual memory without showing any screen output.


2 Answers

You can use "Desktops" application from SysInternals package. Run UI tests on one desktop and work on another.

like image 118
Yauheni Sivukha Avatar answered Oct 18 '22 20:10

Yauheni Sivukha


I found a freeware program called "RunProcess.exe" written by Frank P. Westlake that can run a process bound to the desktop of a non-interactive (e.g. off-screen) WindowStation. However, there is no source.

Therefore I've implemented my own version (simpler than Frank Westlake's) with Java and JNA. It's in the Window Licker repository in the tools module. The class is called com.objogate.wl.win32.RunOnDesktop. At some point I may port it to C and make it a normal command-line .exe, or maybe turn it into an Ant task for running tests off-screen.

like image 44
Nat Avatar answered Oct 18 '22 22:10

Nat