Go to file
Pekka Paalanen f5b74f7ded tests: ivi_layout test infrastructure
Testing the ivi_layout API requires two things:
- the tests must be written as a controller module to access the API
- the tests need a helper client to create some objects that can then be
  managed via the API

This patch adds all the infrastructure and two different kinds of
example tests.

Internal ivi-shell (ivi_layout) API tests are listed as ivi-*.la files
in TESTS in Makefile.am. Weston-tests-env detects these, and runs Weston
with ivi-shell, and loads the given module as a controller module, not
as a normal plugin.

The test controller module ivi-*.la will launch a helper client. For
ivi-layout-test.la the helper client is ivi-layout.ivi.

The helper client uses the weston-test-runner framework to fork and exec
each TEST with a fresh connection to the compositor.

The actual test is triggered by the weston_test_runner protocol
interface, a new addition to weston-test.xml. The helper client uses
weston_test_runner to trigger a test, and the server side of the
interface is implemented by the test controller module
(ivi-layout-test.la).

The server side of weston_test_runner uses the same trick as
weston-test-runner.h to gather a list of defined tests. A test is
defined with the RUNNER_TEST macro.

If a test defined by RUNNER_TEST succeeds, an event is sent to the
helper client that it can continue (or exit). If a test fails, a fatal
protocol error is sent to the helper client.

Once the helper client has iterated over all of its tests, it signals
the batch success/failure via process exit code. That is cought in the
test controller module, and forwarded as Weston's exit code.

In summary: each ivi_layout test is a combination of a client side
helper/setup and server side actual tests.

v2: Load weston-test.so, because create_client() needs it.

v3: add a comment about IVI_TEST_SURFACE_ID_BASE.

v4: Rebased to upstream weston-tests-env changes.

Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Reviewed-by: Derek Foreman <derekf@osg.samsung.com> (v2)
2015-04-09 09:27:05 +03:00
clients nested-client: fix typo 2015-03-30 15:28:24 +03:00
data data: add reference image files for weston-ivi-shell-user-interface 2014-12-04 17:24:54 +02:00
desktop-shell xwm: tell the shell the pid of the X clients 2015-03-30 16:04:57 +03:00
fullscreen-shell compositor: Refactor weston_output_mode_switch() 2014-11-05 13:15:13 +02:00
ivi-shell ivi-shell/weston.ini: fix paths 2015-04-07 14:46:08 +03:00
m4 weston-build: Fix aclocal error during autogen.sh 2014-06-21 10:33:21 -07:00
man compositor: add option to specify a weston.ini 2015-03-27 09:38:19 +02:00
protocol tests: ivi_layout test infrastructure 2015-04-09 09:27:05 +03:00
shared toytoolkit: fix EGL surface creation for lazy drivers 2015-03-30 15:42:16 +03:00
src gl-renderer: fix configless_context check 2015-04-08 16:41:07 +01:00
tests tests: ivi_layout test infrastructure 2015-04-09 09:27:05 +03:00
wcap wcap: Check for mmap and malloc return value in wcap decode module 2014-05-06 15:21:27 -07:00
xwayland xwm: fix extra break 2015-04-08 15:21:17 +03:00
.gitignore tests: ivi_layout test infrastructure 2015-04-09 09:27:05 +03:00
COPYING Add COPYING 2012-04-25 10:17:42 -04:00
Makefile.am tests: ivi_layout test infrastructure 2015-04-09 09:27:05 +03:00
README README: Fix typo; add link to testing docs 2014-02-05 17:20:24 -08:00
autogen.sh Update autotools configuration 2010-11-06 21:04:03 -04:00
configure.ac configure.ac: make use of wayland-scanner.pc 2015-02-23 18:01:46 -08:00
notes.txt Add informal notes file 2012-10-25 15:00:42 -04:00
releasing.txt releasing: Note that Xwayland installation required only for Weston releases 2015-02-13 20:46:41 -08:00
weston.ini.in libinput: Add tap configuration to weston.ini 2014-08-15 15:33:55 +03:00

README

Weston

Weston is the reference implementation of a Wayland compositor, and a
useful compositor in its own right.  Weston has various backends that
lets it run on Linux kernel modesetting and evdev input as well as
under X11.  Weston ships with a few example clients, from simple
clients that demonstrate certain aspects of the protocol to more
complete clients and a simplistic toolkit.  There is also a quite
capable terminal emulator (weston-terminal) and an toy/example desktop
shell.  Finally, weston also provides integration with the Xorg server
and can pull X clients into the Wayland desktop and act as a X window
manager.

Refer to http://wayland.freedesktop.org/building.html for building
weston and its dependencies.

The test suite can be invoked via `make check`; see
http://wayland.freedesktop.org/testing.html for additional details.