Meego Wiki
Views

Quality/TestSuite/X11 Test Specification

From MeeGo wiki
< Quality | TestSuite(Difference between revisions)
Jump to: navigation, search
m
 
(2 intermediate revisions not shown)
Line 23: Line 23:
Current coverage for X11 tests:  
Current coverage for X11 tests:  
-
*  
+
 
 +
* [[http://gitorious.org/qa-tools/mcts-coverage/blobs/master/X11-coverage_generated.ods X11-coverage_generated.ods]]
 +
 
===  Hardware Coverage ===  
===  Hardware Coverage ===  
Line 41: Line 43:
No specific hardware setup is required. The test environment must be running an X11 server, and must have the following packages installed:
No specific hardware setup is required. The test environment must be running an X11 server, and must have the following packages installed:
-
* libbltscommon1
+
* [[../BLTS Common Library | libbltscommon1]]
* libX11
* libX11
* libXdamage
* libXdamage
Line 53: Line 55:
=== Building the test asset ===
=== Building the test asset ===
-
The build enviroment must have the following packages installed:
+
The build environment must have the following packages installed:
-
* libbltscommon1-devel
+
* [[../BLTS Common Library | libbltscommon1-devel]]
* libX11-devel
* libX11-devel
* libXdamage-devel
* libXdamage-devel
Line 65: Line 67:
* libXi-devel
* libXi-devel
-
The test asset sources include the pack.sh script, which is used for building RPM and Debian packages and source tar packages. To build an RPM package with the script, execute this command in the toplevel source directory of blts-sensors-frontend:
+
{{:Quality/TestSuite/Building_BLTS_Packages}}
-
 
+
-
./pack.sh -r
+
-
 
+
-
To get help about the packaging script, execute
+
-
 
+
-
./pack.sh -h
+
-
 
+
-
The asset can also be built manually by executing:
+
-
 
+
-
./autogen.sh
+
-
./configure
+
-
make
+
=== Test asset specific instructions ===
=== Test asset specific instructions ===

Latest revision as of 11:38, 17 December 2010

Contents

Introduction

The X Window System (commonly X or X11) is a computer software system and network protocol that provides a graphical user interface (GUI). Base X Window System is extended by X Extension libraries (mainly from freedesktop.org and XFree86 projects).

The blts-x11 test driver includes functional tests for X11 using xlib, and for various X Extensions using their user space libraries

Test Coverage

The test driver currently covers basic functionalities of X11 and it's extensions, including:

  • X11 presence check
  • Enumerating and checking needed X Extensions
  • Basic window creation operations and drawing
  • XComposite: Rendering to off-screen buffer
  • XDamage: Creating and monitoring 'damage' regions
  • XInput: Accessing (listing) available input devices
  • XRender: Simple drawing
  • XRandR: Dynamically change X screen (rotation/orientation)
  • XRecord: Recording X protocol events (such as mouse movement)
  • XTest: Generating input device events (for example generating mouse movement events)
  • XVideo: Overlay video output

Software Coverage

Current coverage for X11 tests:


Hardware Coverage

Mainly display devices (and GPU).

Limitations

TBD

Future Improvements

Extend functional coverage of existing test and create performance tests for XVideo, XComposite and DRI2.

Running the tests

Hardware setup and test environment

No specific hardware setup is required. The test environment must be running an X11 server, and must have the following packages installed:

  • libbltscommon1
  • libX11
  • libXdamage
  • libXcomposite
  • libXrandr
  • libXrender
  • libXtst
  • libXv
  • libXi

Building the test asset

The build environment must have the following packages installed:

  • libbltscommon1-devel
  • libX11-devel
  • libXdamage-devel
  • libXcomposite-devel
  • libXrandr-devel
  • libXrender-devel
  • libXtst-devel
  • libXv-devel
  • libXi-devel

The source package includes the pack.sh script, which is used for building RPM and Debian packages and source tar packages. To build an RPM package with the script, execute this command in the top level source directory of asset:

./pack.sh -r

To get help about the packaging script, execute

./pack.sh -h

The asset can also be built manually by executing:

./autogen.sh
./configure
make

Test asset specific instructions

The test package can be installed in the device with the command

rpm -ivh blts-x11_{version}.rpm

Test case arguments

General Switch Function
-l Used log file
-e Execute single or multiple selected tests, for example -e 1,4,5.
-en Execute test by name, for example -en "My test X"
-s Show list of all tests
-C Used configuration file
-? Help message
-xml, -axml Create result XML. -axml appends results to an existing XML file.
-auto Silent logging for test automation. Only the results are printed to stdout.
-v Verbose logging (default)
-vv Even more verbose logging
Optional Switch Function
-t Maximum execution time of each test in seconds (default: 10s)

Running test cases

Test cases must be executed with root privileges.

Test case descriptions and execution commands:

  • X11-X11 presence check
    • Check that required X11 components are present in the test device
    • blts-x11-tests -en "X11-X11 presence check"
  • X11-Create simple window
    • Create a simple X11 window and execute string and rectangle drawing tests
    • blts-x11-tests -en "X11-Create simple window"
  • X11-Enumerate X extensions
    • Enumerate X extensions supported by the X11 server
    • blts-x11-tests -en "X11-Enumerate X extensions"
  • X11-XVideo init
    • Check that XVideo initialization works on configured screens, and test XVideo image output
    • blts-x11-tests -en "X11-XVideo init"
  • X11-XTest move cursor
    • Test cursor movement using the XTest extension
    • blts-x11-tests -en "X11-XTest move cursor"
  • X11-XComposite get window contents
    • Check that window contents can be captured using the XComposite extension
    • blts-x11-tests -en "X11-XComposite get window contents"
  • X11-XRecord capture mouse movement
    • Check that mouse movement can be captured using the XRecord extension
    • blts-x11-tests -en "X11-XRecord capture mouse movement"
  • X11-XRender draw rectangle
    • Test rectangle drawing using the XRender extension
    • blts-x11-tests -en "X11-XRender draw rectangle"
  • X11-XRandR rotate screen
    • Test screen rotation using the XRandR extension
    • blts-x11-tests -en "X11-XRandR rotate screen"
  • X11-XDamage monitor region
    • Check that screen region monitoring works using the XDamage extension
    • blts-x11-tests -en "X11-XDamage monitor region"
  • X11-XInput enumerate devices
    • Enumerate XInput devices
    • blts-x11-tests -en "X11-XInput enumerate devices"

Module Design and Architecture

The test module can be compiled to a self-sufficient command line program. Debian and RPM packaging is provided.

Architecture diagram

References

X11 X11 home page
freedesktop.org freedesktop.org home page
XFree86 XFree86 home page

Change History

Version Date Handled By Status Comments
0.1 22-sep-2010 Iekku Huttunen Draft Page created
0.2 08-Dec-2010 Pasi Matilainen Draft Test running instructions updated
Personal tools