Commit Graph

15 Commits

Author SHA1 Message Date
Olivier Fourdan
f788289bdc xfree86: Use libxcvt
Replace the local implementation of the VESA CVT standard timing
modelines generator with the one from libxct to avoid code duplication.

Closes: https://gitlab.freedesktop.org/xorg/xserver/-/issues/1142
Signed-off-by: Olivier Fourdan <ofourdan@redhat.com>
Reviewed-by: Matt Turner <mattst88@gmail.com>
2021-08-06 11:29:29 +00:00
Povilas Kanapickas
d231ce2d9c meson: Disable LTO for tests
`-flto=auto` together with `-Wl,-wrap` causes link errors at least in
certain compilers (e.g. GCC 10.2.0). Since this is reoccurring issue
(internet search shows similar problems with GCC 4.6 a decade ago) let's
disable LTO for tests even if it's disabled elsewhere.

Fixes: https://gitlab.freedesktop.org/xorg/xserver/-/issues/1116
Signed-off-by: Povilas Kanapickas <povilas@radix.lt>
2021-04-09 11:18:54 +00:00
Olivier Fourdan
3cdac5ba07 mi: List extensions in usage message
Not all extensions can be enabled or disabled at runtime, list the
extensions which can from the help message rather than on error only.

v2:
 * Print the header message in the ListStaticExtensions() (Peter
   Hutterer)
 * Do not export ListStaticExtensions() as Xserver API

Signed-off-by: Olivier Fourdan <ofourdan@redhat.com>
Reviewed-by: Michel Dänzer <mdaenzer@redhat.com>
2021-01-29 12:52:09 +00:00
Michel Dänzer
250db8708a xwayland: Add and hook up test script
It runs XTS via piglit on (non-rootless) Xwayland on weston using the
headless backend.

Xwayland might use glamor if enabled in the build, but we're making sure
it uses software rendering.

v2:
* Use weston-info to wait for weston to be ready, instead of just a
  fixed sleep. (Martin Peres)
v3:
* Build wayland 1.18 & weston 9.0 locally, since the packages in Debian
  buster are too old for current Xwayland.

Acked-by: Olivier Fourdan <ofourdan@redhat.com>
2020-11-17 18:21:37 +01:00
Jon Turney
1f5742d271 meson: Fix building unit tests when protocol headers aren't in default include path 2019-04-29 11:49:46 +00:00
Eric Anholt
0a005c4fe4 test: Fix meson build with xvfb disabled.
Fixes #678

Signed-off-by: Eric Anholt <eric@anholt.net>
2019-04-04 16:26:40 -07:00
Jon Turney
f1790339d0 tests: Always separate rendercheck -f and -o options with a space 2019-04-02 13:12:42 +01:00
Eric Anholt
3f3c489e51 test: Trim the Render ops that we test the composite paths on.
We cover all Render ops under the "blend" group, so when we're doing
the cross products of some formats for the masking operation, skip
most of the ops (covering just zero, one, and src/dst alpha blend
factors along with a definitely non-glamor-accelerated one) .

All the tests now complete in <20s of runtime on my skylake.

Signed-off-by: Eric Anholt <eric@anholt.net>
2019-03-28 13:55:22 -07:00
Eric Anholt
58c168ad93 test: Execute rendercheck tests without using piglit.
This gets us parallelism between rendercheck tests at the cost of
spinning up more Xvfbs, and nicer logging of the tests that are run.

Signed-off-by: Eric Anholt <eric@anholt.net>
2019-03-28 13:55:19 -07:00
Jon Turney
9114c4341c meson: Drop a meson version check
Drop some code conditional on meson version, which is not needed
since 7e046b94 bumped the minimum meson version
2019-03-14 21:23:23 +00:00
Jon Turney
0e541b1093 meson: Add misc unit tests
v2:
has_link_argument requires meson 0.46.0
2018-12-14 11:32:31 +00:00
Eric Anholt
89901e14d2 test: Add the start of a testsuite for damage.
Inspired by the previous bug, build something we can use to write
damage testcases, including testing for the bug.

Signed-off-by: Eric Anholt <eric@anholt.net>
2018-09-25 21:27:08 -07:00
Eric Anholt
14af8bee24 test: Add a test for the overflow bug in bigreqs.
The failing struct comes from the python test written by Michal Srb
<msrb@suse.com>.

v2: Use a drawable (root window) and gc, so that PolyLines hopefully
    actually tries processing things.  However, the request seems to
    process successfully so the poll() just stalls out.  However, this
    does let us distinguish between detecting the bigrequests error
    and not, at least.
v3: Clean up the description of what we expect the poll() call to do.
v4: Use XI2 instead of PolyLine to trigger a predictable error. We know the
    server replies with BadValue for a zero num_masks argument. So if we send
    a bigreq with a num_masks 0 and a length 0, we can just check whether we
    get killed (good) or a BadValue (bad). It doesn't test for specific memory
    overflows or crashes, but based on the assumption that we shouldn't look
    at *any* BigReq of size 0, this seems to be sufficient.

Signed-off-by: Eric Anholt <eric@anholt.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-11-01 10:29:00 +10:00
Eric Anholt
5cbfa27654 test: Add basic SYNC tests.
I couldn't find any, and I was modifying the implementation, so I had
to write some.  I would like the test to end with a "make sure there
weren't any stray unchecked errors", but I didn't figure out how to do
that.

v2: Extend sync tests to cover alarm delta and waitvalue changes.

Signed-off-by: Eric Anholt <eric@anholt.net>
Reviewed-by: Keith Packard <keithp@keithp.com>
2017-09-20 13:19:27 -04:00
Eric Anholt
a8eeb332cc meson: Add Xvfb and Xephyr-glamor testing.
The Xvfb tests are passing and Xephyr-glamor is failing for me, but it
fails identically on autotools.  It's disabled on Travis for now
because the >10 minutes of silence during testing times out the entire
build.

v2: Fix the disable on travis.

Signed-off-by: Eric Anholt <eric@anholt.net>
Reviewed-by: Adam Jackson <ajax@redhat.com>
2017-09-20 13:19:25 -04:00