summaryrefslogtreecommitdiff
diff options
authorSylvain Pineau <sylvain.pineau@canonical.com>2017-08-24 17:16:00 +0200
committerSylvain Pineau <sylvain.pineau@canonical.com>2017-08-24 17:16:00 +0200
commitce824e12e3f4d544506a4eb2d6ffcdb0325c4126 (patch)
tree37cc82bcbc2e65f726add0b9bc83243514a7310e
parent1cbb3c3c1c9e46d2d0468e951acc8edcd15ce9aa (diff)
graphics: Add a pretest to check the opengl renderer (AMD GPU and DRI_PRIME=1)
Fixes: LP:1712018
-rw-r--r--jobs/graphics.txt.in16
1 files changed, 16 insertions, 0 deletions
diff --git a/jobs/graphics.txt.in b/jobs/graphics.txt.in
index 036c138..a7af65a 100644
--- a/jobs/graphics.txt.in
+++ b/jobs/graphics.txt.in
@@ -279,6 +279,22 @@ _summary: Test Unity 3D support for {vendor} {product}
unit: template
template-resource: graphics_card
+template-filter: graphics_card.driver in ['amdgpu', 'amdgpu-pro']
+plugin: shell
+category_id: com.canonical.plainbox::graphics
+id: graphics/{index}_valid_opengl_renderer_{product_slug}
+requires: package.name == 'mesa-utils'
+command:
+ renderer=`DRI_PRIME=1 glxinfo | grep "OpenGL re"`
+ echo $renderer
+ if grep -qi 'Intel' <<<$renderer; then
+ echo 'ERROR: renderer is Intel when DRI_PRIME=1'
+ exit 1
+ fi
+_summary: Check the OpenGL renderer (AMD GPU and DRI_PRIME=1)
+
+unit: template
+template-resource: graphics_card
plugin: user-interact-verify
category_id: com.canonical.plainbox::graphics
id: graphics/{index}_glxgears_{product_slug}