Commit 90b697d1 authored by Guido Gunther's avatar Guido Gunther
Browse files

tests: Check for drm render node

parent 37e68d94
import os
import subprocess
NODE = '/dev/dri/renderD128'
def udev_props(path):
out = subprocess.check_output(['udevadm', 'info', '-qproperty', path]).decode('utf-8')
props = {}
for line in out.split('\n'):
if not line.strip():
k, v = line.strip().split('=', 1)
props[k] = v
return props
def test_render_node():
"Test if we have a render node"
def test_etnaviv_node():
"Test if the render node is etnaviv"
props = udev_props(NODE)
assert(props['ID_PATH'] == 'platform-etnaviv')
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment