jw-devtest/src/python/devtest/os/test/cases/Eth1.py
Jan Lindemann 4b912741cb First commit
Signed-off-by: Jan Lindemann <jan@janware.com>
2025-11-17 11:12:21 +01:00

21 lines
736 B
Python

# -*- coding: utf-8 -*-
from devtest.os import TestCase
from devtest.os.test import *
class Eth1(TestCase): # export
def __init__(self, regex = None, act_timeout=30, total_timeout=None):
self.regex = regex
self.act_timeout = act_timeout
self.total_timeout = total_timeout
async def _run(self, env, machine, phase):
console = get_console(env)
regex = self.regex
if regex is None:
regex = "Searching for eth1 driver: found"
if await expect(console, regex=regex, subject="load eth1 driver",
act_timeout=self.act_timeout, total_timeout=self.total_timeout) is None:
return "timed out waiting for set eth1 driver"
return None