Path: utzoo!utgpu!jarvis.csri.toronto.edu!clyde.concordia.ca!uunet!snorkelwacker!bloom-beacon!EXPO.LCS.MIT.EDU!rws From: rws@EXPO.LCS.MIT.EDU (Bob Scheifler) Newsgroups: comp.windows.x Subject: Re: Client Exercizer Tool Message-ID: <8912201825.AA09195@expire.lcs.mit.edu> Date: 20 Dec 89 18:25:42 GMT References: <8912201713.AA02485@amd-20.> Sender: daemon@athena.mit.edu (Mr Background) Organization: The Internet Lines: 2227 The tool is on the Test Suite tape. Here's info on the tape, followed by some man pages. The Alpha release of the X Testing Consortium's X Test Suite is now available via anonymous ftp to expo.lcs.mit.edu (18.30.0.212), in the directory /pub/XTEST/, as a split compressed tar file. The distribution is approximately 36Mb uncompressed. The suite can also be ordered from the MIT Software Center. The suite is available on one 2400ft, 1600bpi 9-track magnetic reel to reel tape written in UNIX tar format. No other distribution format is available from MIT. The tape contains source code and is distributed with a hardcopy of the documentation. To obtain a copy of the X Test Suite, please send a check drawn on a U.S. bank payable to the "Massachusetts Institute of Technology" for US $200 to: MIT Software Center Bldg. E32-300 28 Carleton Street Cambridge, MA 02139 Please send wire transfers to: First National Bank of Boston 100 Federal Street Boston, MA 0211) Acct #51463306 Reference: (your company name)M.I.T. Technology Licensing Office Please send a shipping address with your order. P.O. Boxes are undeliverable via UPS. If you have ordering questions, you can call the X Hotline at (617) 258-8330. The X Testing Consortium was formed (prior to the formation of the MIT X Consortium) to develop code suitable for testing the correctness and robustness of vendor implementations of the X Window System. This release of the test suite contains the following components: 1. Protocol Sanity Tests. These test the server's basic ability to accept all legal message types and respond appropriately, test aspects which cannot be tested adequately from Xlib, and test basic server functionality that the Xlib tests depend on. 2. Xlib Tests. Comprehensive tests for most routines and macros in the Xlib interface, testing both Xlib and the server. Includes pixel validation of graphics requests. 3. Xlib Test Specifications. Informal written specifications of what the Xlib Tests should do. 4. Volume/Stress Tests. Tests server robustness with high data load and high computational load sustained over both short and long periods of time, and provides a framework for adding additional tests. 5. Client Exerciser. Utilities for recording and playing back scripts of user actions (keyboard and pointer events), for the purpose of testing clients. The utilities make use of the Input Synthesis Extension (distributed as part of X11 Release 3 from MIT). 6. Graphics Benchmark. Yet another graphics benchmark tool. 7. Interactive Xlib. A test program which will read and execute Xlib functions and macros, both interactively and from input control files. 8. Gbench. A graphics benchmark tool from Stanford. This was not developed by the X Testing Consortium, it is simply included here as another utility. This is an ALPHA release of the test suite. It is not complete, and there is no particular guarantee that any problems reported by this suite are really bugs in your Xlib or server implementation, they may well be bugs in the test suite itself. The contents of this tape are not endorsed as any form of standard by the X Consortium. This test suite is the result of considerable work by numerous people in the companies making up the X Testing Consortium, and we are indebted to them. MIT was not directly involved in the development of the test suite, but did meet with the X Testing Consortium on a regular basis. This release of the test suite has not gone through MIT's configuration and build process, so it may take some effort to build the suite on your machine. Although there is much work left to be done, this test suite represents an excellent beginning. With this release, the X Testing Consortium is disbanding, but the MIT X Consortium will continue the development of X testing software. .TH XTMCONVERT 1 .ad b .SH NAME xtmconvert \- convert test scripts to and from other formats .SH SYNOPSIS .B xtmconvert [\fB-s\fR] \fIfromfile\fR \fItofile\fR .SH DESCRIPTION .I Xtmconvert converts test scripts in .B internal format to or from .B summary or .B output formats. The type of conversion performed depends on the ending characters of the file names. .SS File Name Syntax The file names given to .I xtmconvert must end in ".scr", ".out", or ".sum". The first file name is the file to be converted. The second file name is the file where the results of the conversion are placed. .PP To convert from .B internal format to .B output format, use: .PP .RS xtmconvert testscript.scr testscript.out .RE .PP To convert from .B internal format to .B summary format, use: .PP .RS xtmconvert testscript.scr sumscript.sum .RE .PP To convert from .B output format to .B internal format, use: .PP .RS xtmconvert oldscript.out newscript.scr .RE .PP To convert from .B summary format to .B internal format, use: .PP .RS xtmconvert testscript.sum testscript.scr .RE .PP .PP If no file names or incorrect file names are given, .I xtmconvert will display the correct invocation syntax and terminate with a non-zero exit status value. .SS Running Xtmconvert .I Xtmconvert may be run in an X terminal emulator or on a terminal. If you run .I xtmconvert on a terminal, make sure that the .B DISPLAY environment variable is set to the name of the desired X server. .PP .I Xtmconvert uses the X server to convert between key codes and the corresponding key names. .PP If no error occurs during the conversion, .I xtmconvert will terminate with an exit status value of zero. If an error occurs during the conversion, .I xtmconvert will terminate with a non-zero exit status value. .PP If the .B -s option is used then any recorded image data or checksums contained in the test script are left out of the converted test script. This is useful if you are moving test scripts to a different machine, since the image data or checksums are almost always machine-specific. .SS Contents of a Test Script All test scripts must contain a version number. The version number is checked when the test script is converted to help deal with future changes to the test script format. If a test script does not have a version number or has a version number that .I xtmconvert does not know how to convert, .I xtmconvert will terminate with a non-zero exit status. .PP A test script may contain four types of input actions: .TP .B key or mouse button presses or releases This input action contains which key or mouse button was pressed or released. .TP .B relative pointer motions This input action contains the relative offset from the current pointer position to the new pointer position. This input action has a maximum range of 15 pixels from the current pointer position. If the pointer must move further than 15 pixels then a pointer jump input action must be used. .TP .B pointer jumps This input action contains x and y coordinates for the pointer to move to. The coordinates are zero in the upper left corner of the screen, the x coordinate increases horizontally from left to right, and the y coordinate increases vertically from top to bottom. .TP .B time delays This input action contains the amount of time to delay before going on to the next input action. .PP Each input action has a time delay before the input action is performed. Except for the time delay input action, the input actions have a limited range of 0 to 65535 milliseconds (approximately one minute). The time delay input action has a range of 0 to 2,147,483,647 milliseconds (approximately 25 days). .PP A test script may contain four types of requests for verification of image data from the display: .TP .B mouse The image data to be verified comes from the window that is a child of the root window and that contains the mouse (pointer) at the time that the request occurs. .TP .B screen The image data to be verified comes from the entire screen. .TP .B top The image data to be verified comes from the window that is a child of the root window and that is the "top" window (as defined by the X server) at the time that the request occurs. .TP .B partial The image data to be verified comes from a partial window specified by the user. .PP The method of image data verification depends on the checksum mode. If the checksum mode is turned off when the request occurs, the image data is verified by comparing the image data with image data stored in the test script. If the checksum mode is turned on when the request occurs, the image data is verified by comparing a checksum computed from the image data with a checksum stored in the test script. .PP A test script may contain checksum mode commands that turn the checksum mode on or off. The checksum mode is turned off at the start of each test script. .PP To change the checksum mode for all or part of an existing test script, convert the test script to .B output format, edit the .B output format of the test script to add or modify any desired checksum mode commands, and convert the test script back to .B internal format. .PP A test script may also contain comments, which have no effect on the execution of a test script. .SS Internal Format The data in the .B internal format of the test script is organized in a way that is convenient for .I xtmrecord(1) and .I xtmexecute(1) to use, but is not easily readable by human beings or portable across different computer systems. .PP The .B internal format of the test script may be created by .I xtmconvert or .I xtmrecord(1) and is the required format of the test script if it is to be played back by .I xtmexecute(1). .PP The .B internal format of the test script contains all of the data in the test script. It is stored in a file whose name ends in ".scr". .PP A test script in .B internal format with no recorded image data for the image data comparison requests would have to be updated (by running .I xtmexecute(1) with the .B -u option) before being used as a test script. .SS Output Format The data in the .B output format of the test script is organized in a way that is more portable across different computer systems. The data is possible for a human being to understand, but the level of detail tends to obscure what the test script is doing. .PP The .B output format of the test script may be created by .I xtmconvert or by an editor, but if you want to create a test script with an editor it is much easier to create a test script in the .B summary format. .PP The .B output format of the test script is stored in a file whose name ends in ".out". .PP The .B output format of the test script contains all of the data in the test script. When converting between .B internal format and .B output format all of the information in the test script is preserved. .PP When .I xtmconvert is converting from .B internal format to .B output format the version number is converted to a line containing: .PP .RS .B VERSION [\fIversionnumber\fB]\fR .RE .PP The .I versionnumber value holds the current version number of the test script. .PP When .I xtmconvert is converting from .B internal format to .B output format each input action is converted to a line containing the following fields: .TP .B input action name This field contains the name of the input action. The contents of this field is described for each type of input action below. .TP \fBDEV [\fIdevicenumber\fB]\fR The .I devicenumber value holds the value for the device that generated the input action. This is a provision for future support of multiple (distinguishable) devices. It should be 0 for most X servers. For most Hewlett Packard X servers it will have the following values: .RS .RS .sp .TP 0 Pointer jump input actions generated by .I xtmrecord(1) or the .I Input Synthesis extension. These may occur at several places in the test script. .TP 1 Pointer jump and relative pointer motion input actions generated by the X server. Also mouse button press or release input actions. .TP 3 Key press or release input actions. .RE .RE .TP .B input action specific information This field contains information specific to the type of the input action. The contents of this field are described for each type of input action below. .TP \fBTIME (ms) [\fItimedelay\fB]\fR The .I timedelay value holds the time delay value associated with the input action. .TP \fBCOUNT [\fIcount\fB]\fR The .I count value holds an input action counter to help make it easier to tell how many input actions are in the test script. .IP This field must be present when converting a test script from .B output format to .B internal format, but the .I count value is ignored. This allows someone to modify the input actions in a test script in .B output format without later causing an error while converting the test script back to .B internal format. .PP A key press input action has an input action name of .B KEY_DOWN and puts: .PP .RS \fBKEY [\fIkeyname\fB]\fR .RE .PP in the input action specific information field. .PP A key release input action has an input action name of .B KEY_UP and puts: .PP .RS \fBKEY [\fIkeyname\fB]\fR .RE .PP in the input action specific information field. .PP The .I keyname value is the X server's name for that key on the X server's keyboard. It may be composed of a single character for common keys (such as .B a for the key labled `A' on the keyboard), or it may be composed of multiple characters for other keys (such as .B bracketleft for the key labeled `[' on the keyboard). .PP The mouse buttons do not have a key name defined for them by the X server. .I Xtmconvert uses .B Button1, Button2, Button3, and so forth as the equivalent of the key name for the mouse buttons. Otherwise, the mouse button input actions are treated the same as the key input actions. .PP A pointer jump input action has an input action name of .B JUMP and puts: .PP .RS \fBX [\fIxpixloc\fB] Y [\fIypixloc\fB]\fR .RE .PP in the input action specific information field. The .I xpixloc and .I ypixloc values are the x and y coordinates of the pixel that the pointer will move to. .PP A relative pointer motion input action has an input action name of .B MOVE and puts: .PP .RS \fBX [\fIxpixmov\fB] Y [\fIypixmov\fB]\fR .RE .PP in the input action specific information field. The .I xpixmov and .I ypixmov values are the relative offsets from the current pointer position to the new pointer position. .PP A time delay input action has an input action name of .B TIME and puts nothing in the input action specific information field. Also, a time delay input action does not have a device field. .PP Requests for verification of image data from the display are converted to six header lines containing the following fields: .TP \fB MATCH #\fImatchnum\fR The .I matchnum value holds an counter of the number of requests for image data verifications in the test script. It will start at 1 for the first request, and may range up to 99 (the maximum number of requests permitted in one test script). .TP \fB TYPE[\fItypeletter\fB]\fR The .I typeletter value holds a letter describing the type of the request: .RS .TP .B m The request is to verify the window that is a child of the root window and that contains the mouse at this point in the test script. .TP .B p The request is to verify a user-specified partial window on the X server. .TP .B s The request is to verify the entire screen on the X server. .TP .B t The request is to verify the window that is a child of the root window and that is the "top" window (as defined by the X server) at this point in the test script. .RE .TP \fB REP[\fIrepcount\fB]\fR The .I repcount value holds the number of times to retry the image data verification before deciding that the verification has failed. .TP \fB INTV[\fIinterval\fB]\fR The .I interval value holds the amount of time to wait (in milliseconds) before each retry. .TP \fB CNT[\fIcount\fB]\fR The .I count value holds the number of bytes of compressed image data for this request. .TP \fB CM[\fIchecksummode\fB]\fR The .I checksummode value holds the checksum mode that was in effect for this request. .TP \fB S#\fIscreennum\fR The .I screenum value holds the number of the screen that contained the image data. .TP \fB WX[\fIwindowxorg\fB]\fR The .I windowxorg value holds the x coordinate of the upper left corner of the window that contained the image data. .TP \fB WY[\fIwindowyorg\fB]\fR The .I windowyorg value holds the y coordinate of the upper left corner of the window that contained the image data. .TP \fB WW[\fIwindowwidth\fB]\fR The .I windowwidth value holds the width of the window that contained the image data (in pixels). .TP \fB WH[\fIwindowheight\fB]\fR The .I windowheight value holds the height of the window that contained the image data (in pixels). .sp .TP \fB BW[\fIborderwidth\fB]\fR The .I borderwidth value holds the border width of the window that contained the image data (in pixels). .TP \fB WN"\fIwindowname\fB"\fR The .I windowname value holds the name of the window that contained the image data. .TP \fB X[\fIxpixloc\fB]\fR The .I xpixloc value holds the window-relative x coordinate of the image data. .TP \fB Y[\fIypixloc\fB]\fR The .I ypixloc value holds the window-relative y coordinate of the image data. .TP \fB W[\fIwidth\fB]\fR The .I width value holds the width of the image data (in pixels). .TP \fB H[\fIheight\fB]\fR The .I height value holds the height of the image data (in pixels). .TP \fB D[\fIdepth\fB]\fR The .I depth value holds the depth of the image data. .TP \fB F[\fIformat\fB]\fR The .I format value holds the format of the image data. .TP \fB XOFF[\fIxoffset\fB]\fR The .I xoffset value holds the horizontal offset of the image data. .TP \fB BO[\fIbyteorder\fB]\fR The .I byteorder value holds the byte order of the image data. .TP \fB BU[\fIbitmapunit\fB]\fR The .I bitmapunit value holds the bitmap unit of the image data. .TP \fB BBO[\fIbitmapbitorder\fB]\fR The .I bitmapbitorder value holds the bitmap bit order of the image data. .TP \fB BP[\fIbitmappad\fB]\fR The .I bitmappad value holds the bitmap pad boundary of the image data. .sp .TP \fB BPL[\fIbytesperline\fB]\fR The .I bytesperline value holds the number of bytes for each line (padding included) of the image data. .TP \fB BPP[\fIbitsperpixel\fB]\fR The .I bitsperpixel value holds the number of bits for each pixel of the image data. .TP \fB VC[\fIvisualclass\fB]\fR The .I visualclass value holds the type of the color map of the window that contained the image data. .TP \fB RM[\fIredmask\fB]\fR The .I redmask value holds the red mask for the image data. .TP \fB GM[\fIgreenmask\fB]\fR The .I greenmask value holds the green mask for the image data. .TP \fB BM[\fIbluemask\fB]\fR The .I bluemask value holds the blue mask for the image data. .TP \fB BPR[\fIbitsperrgb\fB]\fR The .I bitsperrgb value holds the log (base 2) of the number of distinct color values in the image data. .TP \fB CE[\fIcolormapentries\fB]\fR The .I colormapentries value holds the number of color entries in the color map of the window that contained the image data. .TP \fB C[\fIncolors\fB]\fR The .I ncolors value holds the number of color structures used to describe the color entries in the color map of the window that contained the image data. .PP The header lines will be followed by one line for each color map entry containing the following fields: .TP \fB PIXEL[\fIpixelnumber\fB]\fR The .I pixelnumber value holds the color map entry number for this color. .TP \fB RED[\fIredvalue\fB]\fR The .I redvalue value holds the red value for this color. .TP \fB GREEN[\fIgreenvalue\fB]\fR The .I greenvalue value holds the green value for this color. .TP \fB BLUE[\fIbluevalue\fB]\fR The .I bluevalue value holds the blue value for this color. .TP \fB FLAGS[\fIflags\fB]\fR The .I flags value holds the flags value for this color. .PP If the checksum mode if off, the color map entry lines will be followed by many lines containing the image data in a (run length encoded) compressed form. The image data is compressed by counting the number of bytes of the same value in sequence in the image data (as read from the X server). The count is output as two ascii characters representing hexadecimal digits. The byte value follows as two more ascii characters representing hexadecimal digits. This is repeated until all of the image data is encoded. .PP If the checksum mode is on or the image data has been stripped from the test script, only the header lines will remain. The image data is often stripped when moving a test script from one type of computer to another, since it is machine-dependent. .PP A checksum mode command is converted to a line containing: .PP .RS .B CHECKSUMS \fIchecksummode\fR .RE .PP The .I checksummode value holds the current checksum mode of the test script (either \fBOFF\fR or \fBON\fR). .PP A comment is converted to a line containing: .PP .RS .B COMMENT \fIcomment\fB .RE .PP The .I comment may contain any printable characters except a ">". It should be limited to less than 70 characters. .SS Summary Format The data in the .B summary format of the test script is organized in a way that is easier for a human being to understand and edit. .PP The .B summary format of the test script (except for image verfication data) is stored in a file whose name ends in ".sum". The image verification data is stored in multiple files, one file for each image data verification request in the test script. .PP If the checksum mode if off, the recorded image data is stored in .I xwd(1) format in a fids the y coordinate of the upper left corner of the window that contained the image data. .TP \fB WW[\fIwindowwidth\fB]\fR The .I windowwidth value holds the width of the window that contained the image data (in pixels). .TP \fB WH[\fIwindowheight\fB]\fR The .I windowheight value holds the height of the window that contained the image data (in pixels). .sp .TP \fB BW[\fIborderwidth\fB]\fR The .I borderwidth value holds the border width of the window that contained the image data (in pixels). .TP \fB WN"\fIwindowname\fB"\fR The .I windowname value holds the name of the window that contained the image data. .TP \fB X[\fIxpixloc\fB]\fR The .I xpixloc value holds the window-relative x coordinate of the image data. .TP \fB Y[\fIypixloc\fB]\fR The .I ypixloc value holds the window-relative y coordinate of the image data. .TP \fB W[\fIwidth\fB]\fR The .I width value holds the width of the image data (in pixels). .TP \fB H[\fIheight\fB]\fR The .I height value holds the height of the image data (in pixels). .TP \fB D[\fIdepth\fB]\fR The .I depth value holds the depth of the image data. .TP \fB F[\fIformat\fB]\fR The .I format value holds the format of the image data. .TP \fB XOFF[\fIxoffset\fB]\fR The .I xoffset value holds the horizontal offset of the image data. .TP \fB BO[\fIbyteorder\fB]\fR The .I byteorder value holds the byte order of the image data. .TP \fB BU[\fIbitmapunit\fB]\fR The .I bitmapunit value holds the bitmap unit of the image data. .TP \fB BBO[\fIbitmapbitorder\fB]\fR The .I bitmapbitorder value holds the bitmap bit order of the image data. .TP \fB BP[\fIbitmappad\fB]\fR The .I bitmappad value holds the bitmap pad boundary of the image data. .sp .TP \fB BPL[\fIbytesperline\fB]\fR The .I bytesperline value holds the number of bytes for each line (padding included) of the image data. .TP \fB BPP[\fIbitsperpixel\fB]\fR The .I bitsperpixel value holds the number of bits for each pixel of the image data. .TP \fB VC[\fIvisualclass\fB]\fR The .I visualclass value holds the type of the color map of the window that contained the image data. .TP \fB RM[\fIredmask\fB]\fR The .I redmask value holds the red mask for the image data. .TP \fB GM[\fIgreenmask\fB]\fR The .I greenmask value holds the green mask for the image data. .TP \fB BM[\fIbluemask\fB]\fR The .I bluemask value holds the blue mask for the image data. .TP \fB BPR[\fIbitsperrgb\fB]\fR The .I bitsperrgb value holds the log (base 2) of the number of distinct color values in the image data. .TP \fB CE[\fIcolormapentries\fB]\fR The .I colormapentries value holds the number of color entries in the color map of the window that contained the image data. .TP \fB C[\fIncolors\fB]\fR The .I ncolors value holds the number of color structures used to describe the color entries in the color map of the window that contained the image data. .PP The header lines will be followed by one line for each color map entry containing the following fields: .TP \fB PIXEL[\fIpixelnumber\fB]\fR The .I pixelnumber value holds the color map entry number for this color. .TP \fB RED[\fI is a pointer jump input action. The .I xpixloc and .I ypixloc values are the x and y coordinates of the pixel that the pointer will move to. The .I timedelay value is the number of milliseconds to delay before moving the pointer. .TP .B This is a relative pointer motion input action. The .I xpixmov and .I ypixmov values are the relative offsets from the current pointer position to the new pointer position. The .I timedelay value is the number of milliseconds to delay before moving the pointer. .TP .B