Back to home page

OSCL-LXR

 
 

    


0001 #!/bin/sh
0002 # SPDX-License-Identifier: GPL-2.0
0003 # Runs tests for the intel_sdsi driver
0004 
0005 if ! command -v python3 > /dev/null 2>&1; then
0006         echo "drivers/sdsi: [SKIP] python3 not installed"
0007         exit 77
0008 fi
0009 
0010 if ! python3 -c "import pytest" > /dev/null 2>&1; then
0011         echo "drivers/sdsi: [SKIP] pytest module not installed"
0012         exit 77
0013 fi
0014 
0015 if ! /sbin/modprobe -q -r intel_sdsi; then
0016         echo "drivers/sdsi: [SKIP]"
0017         exit 77
0018 fi
0019 
0020 if /sbin/modprobe -q intel_sdsi && python3 -m pytest sdsi_test.py; then
0021         echo "drivers/sdsi: [OK]"
0022 else
0023         echo "drivers/sdsi: [FAIL]"
0024         exit 1
0025 fi