1
0
Fork 0
Commit graph

1117 commits

Author SHA1 Message Date
Emmanuele Bassi
fa72540246 build: Ensure tests are built only on make check
Tests should only be enabled when we want to run them, or when we are
generating a tarball.
2013-08-19 23:22:38 +01:00
Emmanuele Bassi
edb6e66d90 build: Fix distcheck for conformance tests
We need to export G_TEST_SRCDIR and G_TEST_BUILDDIR if we want to be
able to build the path to the tests data.
2013-07-10 12:31:32 +01:00
Emmanuele Bassi
52e0ec92b7 build: Remove the wrappers directory on clean 2013-07-04 15:48:39 +01:00
Emmanuele Bassi
575b77210b build: Add *.test pattern to the ignored files list 2013-07-03 13:08:26 +01:00
Emmanuele Bassi
f1769d9423 conform/actor-layout: Remove the continuous redraw
We just need one paint cycle.
2013-07-02 23:21:45 +01:00
Emmanuele Bassi
3dad01ac22 conform: Drop the Cogl tests
Cogl has its own (way, way better) test suite these days, so we can drop
our own units here.
2013-07-02 22:36:11 +01:00
Emmanuele Bassi
1124fa9a10 conform: Drop the TODO macro from the harness
The TODO macro is barely used, and it's implemented in terms of
deprecated, not portable API. Let's drop it.
2013-07-02 22:33:58 +01:00
Emmanuele Bassi
4a05ac34fc build: Disable Cogl deprecation warnings for tests
We are exercising all sorts of deprecated API anyway.
2013-07-02 22:26:49 +01:00
Emmanuele Bassi
4787ae2f63 conform: Move timeline-base under conditional check
The timeline base test unit is pretty slow, and under heavy load it will
tend to fail because of skipped frames. We should put it under
conditional testing and only run it if `-m slow` is passed to the test
harness.
2013-07-02 22:23:26 +01:00
Emmanuele Bassi
f1971844b9 conform: Use a repaint function
Timeouts and idles are subject to the whims of the load of the machine
running the tests, as we found out with the new installed tests and
OSTree-based VM running the conformance test suite continuously.

We should be able to use a repaint function and a blocking loop that
either is terminated because we hit g_assert(), or because a flag gets
toggled once we know that the Stage has been at least painted once.

The currently enabled tests using clutter_stage_read_pixels() have been
updated to this approach.

https://bugzilla.gnome.org/show_bug.cgi?id=703476
2013-07-02 22:23:26 +01:00
Colin Walters
8ac9346046 tests/conform/texture-fbo: Log failure better
We might as well print out exactly which assertion failed.
2013-06-24 20:30:40 +01:00
Emmanuele Bassi
de20785b1b conform: Conditionally execute the texture-fbo unit
If we don't have support for offscreen buffers, then there's no point in
testing FBO support in ClutterTexture — a feature that has been long
since deprecated, on a deprecated class.
2013-06-24 19:43:44 +01:00
Colin Walters
18917259fe Revert "Install a11y tests too"
This reverts commit 2b4f47d444.

These are presently "examples" (because they're just run
interactively, not automatable tests).

Conflicts:
	tests/accessibility/Makefile.am
2013-06-24 14:32:16 -04:00
Matthias Clasen
ada04546f0 Fix build with --enable-installed-tests
Space, the ultimate frontier...and the breaker of Makefiles.
2013-06-24 13:37:41 -04:00
Matthias Clasen
3084286874 Install a11y tests too
https://bugzilla.gnome.org/show_bug.cgi?id=702941
2013-06-23 23:28:25 -04:00
Matthias Clasen
e98f32b7c8 Install conformance tests
Install the conformance tests, and metadata to run them
with gnome-desktop-testing-runner.

https://bugzilla.gnome.org/show_bug.cgi?id=702941
2013-06-23 23:28:19 -04:00
Emmanuele Bassi
150090c19b conform: Ensure that we don't leak references
Especially on actors that are not parented and get destroyed.
2013-06-12 10:27:37 +01:00
Emmanuele Bassi
caf6959195 conform: Add suite for actor's meta objects 2013-06-12 10:04:32 +01:00
Emmanuele Bassi
0065fb459c Revert "units: Handle negative values in clutter_units_from_string()"
Stray commit got pushed too soon.

This reverts commit 44f283bb72.
2013-05-22 14:34:22 +01:00
Bastian Winkler
44f283bb72 units: Handle negative values in clutter_units_from_string()
In order to allow values like "-2cm" in ClutterScript,
clutter_units_from_string() needs to handle negative values as well.
2013-05-22 15:26:12 +02:00
Emmanuele Bassi
323ec19dcc build: Remove INCLUDES directives
They have been deprecated for a while, replaced by AM_CPPFLAGS.
2013-05-15 15:18:13 +01:00
Emmanuele Bassi
c9583792cb build: Fix up the silent rules prefixes
Automake increased the whitespace, so we need to do that for our "I
Can't Believe It's Not Autotool™" rules.
2013-05-15 15:07:15 +01:00
Lionel Landwerlin
d1041e1f4f conform: add offscreen effects fbo size check
https://bugzilla.gnome.org/show_bug.cgi?id=699675
2013-05-15 14:58:46 +01:00
Emmanuele Bassi
160c62b2f9 conform: Disable the Cogl tests
Cogl is being tested pretty well, these days; also, there is a failure
in the mipmap test that I really don't have time to bisect.
2013-02-20 23:31:17 +00:00
Rob Bradford
6bef2cff19 conformance: Only check for DISPLAY on X11 windowing backend
Fixes: https://bugzilla.gnome.org/show_bug.cgi?id=693741
2013-02-20 23:06:28 +00:00
Emmanuele Bassi
65a024af92 timeline: Add progress-based marker API
Being able to set a marker at a normalized point on a timeline, instead
of using a specific time, is a nice fit with the current Timeline class
API.

https://bugzilla.gnome.org/show_bug.cgi?id=694319
2013-02-20 23:06:28 +00:00
Nirbheek Chauhan
a783e6d3f2 clutter-text: Allow setting attributes for editable text
The behaviour imitates GtkEntry and ignores attributes from markup because Pango
barfs on invalid markup. Also add an example to the text-field interactive test.

https://bugzilla.gnome.org/show_bug.cgi?id=686477
2013-01-16 22:24:14 +00:00
Emanuele Aina
219d0efcc6 actor: rollback pivot translation even on explicit transforms
When setting an explicit transform with clutter_actor_set_transform()
and a non (0,0) pivot-point, clutter_actor_apply_transform() will fail
to roll back the pivot-point translation done before multiplying the
transformation matrix due to the "out:" label being slightly misplaced
in clutter_actor_real_apply_transform().

This works properly:
  clutter_actor_set_pivot_point (actor, 0.5, 0.5);
  clutter_actor_set_rotation_angle (actor, CLUTTER_Z_AXIS, 30);

This results in the actor being moved to the pivot-point position:
  clutter_actor_set_pivot_point (actor, 0.5, 0.5);
  clutter_matrix_init_identity(&matrix);
  cogl_matrix_rotate (&matrix, 30, 0, 0, 1.0);
  clutter_actor_set_transform (actor, &matrix);

This also add a conformance test checking that even when using a
pivot-point, no matter how a rotation is set the resulting
transformation matrix will be the same.

https://bugzilla.gnome.org/show_bug.cgi?id=690214
2012-12-14 19:15:48 +01:00
Jasper St. Pierre
511e266a85 A bunch of fixes for Coverity
None of these are relevant enough for their own fixes.

https://bugzilla.gnome.org/show_bug.cgi?id=689496
2012-12-02 14:50:54 -05:00
Emanuele Aina
b94595f5f7 tests: Track TOUCH_CANCEL events in test-events 2012-11-26 13:29:36 +01:00
Emanuele Aina
7007273405 tests: Print touch sequences in test-events
https://bugzilla.gnome.org/show_bug.cgi?id=685186
2012-11-26 13:29:36 +01:00
Emanuele Aina
ad288c8061 tests: Print the modifiers state on mouse/touch events 2012-11-26 13:29:36 +01:00
Daniel Stone
13d889814c test: Only run X11-specific code when using X11
The X11-specific windowing checks were hidden behind an #ifdef, however
if the tests were run under Wayland, they would execute uncondionally
and cause assertion failures.  Fix this by also hiding them behind a
check that the current backend is indeed X11.

Signed-off-by: Daniel Stone <daniel@fooishbar.org>
2012-10-12 15:12:55 +01:00
Emanuele Aina
d587fa4e28 tests: print coords and devices in test-events
Print event coordinates on events other than motion and also track
the device and source device ids in ./tests/interactive/test-events

https://bugzilla.gnome.org/show_bug.cgi?id=684552
2012-09-24 17:03:36 +01:00
Emanuele Aina
d616fd628b tests: style fixes to test-events
Oops, I pushed the commit without the style fixes. Followup commit
for 47347d5.
2012-09-12 20:08:16 +02:00
Emanuele Aina
47347d5f5c tests: handle smooth scroll events in test-events
Print the precise scroll delta for smooth scroll events and
correctly print the direction for left/right scrolls.

https://bugzilla.gnome.org/show_bug.cgi?id=683870
2012-09-12 15:31:55 +02:00
Emanuele Aina
8a69210363 tests: track touch events in test-events
Enable xinput support in the X11 backend form test-events to
receive touch[begin|update|end] events.

https://bugzilla.gnome.org/show_bug.cgi?id=683869
2012-09-12 14:57:48 +02:00
Sjoerd Simons
903452d2df interactive/touch-events: Optimize touch event drawing
The current versions redraws all events on every redraw, which starts
getting very slow quickly. Instead simply draw only the new events
except when the cairo surface got reset, in that case redraw all events
again.

https://bugzilla.gnome.org/show_bug.cgi?id=681584
2012-08-10 15:05:43 +01:00
Emmanuele Bassi
41ed9023eb build: Fix out of tree builds 2012-07-30 12:33:24 +01:00
Emmanuele Bassi
25878c6c13 interactive/keyframe: Use transition-stopped signal 2012-07-26 14:01:01 +01:00
Emmanuele Bassi
4546f84408 timeline: Add support for step() progress
The CSS3 Transitions specification from the W3C defines the possibility
of using a parametrized step() timing function, with the following
prototype:

        steps(n_steps, [ start | end ])

where @n_steps represents the number of steps used to divide an interval
between 0 and 1; the 'start' and 'end' tokens describe whether the value
change should happen at the start of the transition, or at the end.

For instance, the "steps(3, start)" timing function has the following
profile:

  1 |           x
    |           |
    |       x---|
    |       '   |
    |   x---'   |
    |   '       |
  0 |---'       |

Whereas the "steps(3, end)" timing function has the following profile:

  1 |       x---|
    |       '   |
    |   x---'   |
    |   '       |
    x---'       |
    |           |
  0 |           |

Since ClutterTimeline uses an enumeration for controlling the progress
mode, we need additional API to define the parameters of the steps()
progress; for this reason, we need a CLUTTER_STEPS enumeration value,
and a method for setting the number of steps and the value transition
policy.

The CSS3 Transitions spec helpfully also defines a step-start and a
step-end shorthands, which expand to step(1, start) and step(1, end)
respectively; we can provide a CLUTTER_STEP_START and CLUTTER_STEP_END
enumeration values for those.
2012-07-19 20:47:00 -04:00
Emmanuele Bassi
d7eb57a711 interactive/animation: Use pivot point
Instead of the anchor point and the rotation center.
2012-07-19 14:18:09 -04:00
Emmanuele Bassi
1da42dd8a0 actor: Add ActorIter.is_valid()
It can be useful to check whether a ClutterActorIter is currently valid,
i.e. if the iterator has been initialized *and* if the actor to which it
refers to hasn't been updated.

We can also use the is_valid() method in the conformance test suite to
check that initialization has been successful, and that changing the
children list through the ClutterActorIter API leaves the iterator in a
valid state.
2012-06-27 21:28:01 +01:00
Emmanuele Bassi
1ca4937f1e conform: Check that iterators work post-assignment
It should be possible to copy a ClutterActorIter just by copying its
contents (either via assignment or memcpy).
2012-06-27 21:28:01 +01:00
Emmanuele Bassi
98982331cb conform/script: Add the return type for the margin test
The compiler would default to 'int', and warn - and then warn again
because the function would not return a value.
2012-06-20 18:58:31 +01:00
Emmanuele Bassi
3ad5502003 interactive/touch-events: Protect x11-specific calls
Use the CLUTTER_WINDOWING_X11 define to protect platform-specific calls
like clutter_x11_enable_xinput().

https://bugzilla.gnome.org/show_bug.cgi?id=678423
2012-06-20 08:53:56 +01:00
Emmanuele Bassi
47f8be4d4b conform: Put xinput enabling under guards
Calling clutter_x11_* API should be done only under the platform
specific guards we provide with Clutter.

https://bugzilla.gnome.org/show_bug.cgi?id=678423
2012-06-20 08:53:46 +01:00
Emmanuele Bassi
b850696b31 interactive/touch-events: Add a missing return value
The draw_touches() function must return a boolean value.

https://bugzilla.gnome.org/show_bug.cgi?id=678391
2012-06-19 12:20:11 +01:00
Emmanuele Bassi
c57cabd4c2 conform/interval: Add transformation unit test
Verify that it's possible to pass a transformable type to
ClutterInterval.
2012-06-18 18:04:54 +01:00
Emmanuele Bassi
aacd28cc21 conform: Initial suite for ClutterInterval
ClutterInterval is undertested, so we should start adding a unit test
for it.
2012-06-18 18:04:54 +01:00