Files
poky/meta-selftest/lib/oeqa/runtime/cases/virgl.py
Richard Purdie f18a7dee06 oeqa/runtime/virgl: Update test to match new mesa version
The output string changed slightly in new mesa versions so update
the test to match.

(From OE-Core rev: 2f1a233e75e7202e2959fee3437def388262c57a)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2022-09-22 21:39:21 +01:00

19 lines
894 B
Python

from oeqa.runtime.case import OERuntimeTestCase
from oeqa.core.decorator.depends import OETestDepends
import subprocess
import oe.lsb
class VirglTest(OERuntimeTestCase):
@OETestDepends(['ssh.SSHTest.test_ssh'])
def test_kernel_driver(self):
status, output = self.target.run('dmesg|grep virgl')
self.assertEqual(status, 0, "Checking for virgl driver in dmesg returned non-zero: %d\n%s" % (status, output))
self.assertIn("features: +virgl", output, "virgl acceleration seems to be disabled:\n%s" %(output))
@OETestDepends(['virgl.VirglTest.test_kernel_driver'])
def test_kmscube(self):
status, output = self.target.run('kmscube')
self.assertEqual(status, 0, "kmscube exited with non-zero status %d and output:\n%s" %(status, output))
self.assertIn('renderer: "virgl', output, "kmscube does not seem to use virgl:\n%s" %(output))