diff --git a/tests/driver_apds99xx/tests/01-run.py b/tests/driver_apds99xx/tests-with-config/01-run.py similarity index 80% rename from tests/driver_apds99xx/tests/01-run.py rename to tests/driver_apds99xx/tests-with-config/01-run.py index a8cf62fa38..be7bcf3740 100755 --- a/tests/driver_apds99xx/tests/01-run.py +++ b/tests/driver_apds99xx/tests-with-config/01-run.py @@ -11,11 +11,8 @@ from testrunner import run def testfunc(child): - child.expect('Initializing APDS99XX sensor') - i = child.expect(['[OK]', '[Failed]']) - if i == 1: - print('FAILED') - return + child.expect_exact('Initializing APDS99XX sensor') + child.expect_exact('[OK]') child.expect(r'proximity = \d+ \[cnts\]') child.expect(r'ambient = \d+ \[cnts\]') child.expect([r'red = \d+ \[cnts\], green = \d+ \[cnts\], blue = \d+ \[cnts\]', diff --git a/tests/driver_apds99xx_full/tests/01-run.py b/tests/driver_apds99xx_full/tests-with-config/01-run.py similarity index 79% rename from tests/driver_apds99xx_full/tests/01-run.py rename to tests/driver_apds99xx_full/tests-with-config/01-run.py index fd84d416cf..429b8920b8 100755 --- a/tests/driver_apds99xx_full/tests/01-run.py +++ b/tests/driver_apds99xx_full/tests-with-config/01-run.py @@ -11,11 +11,8 @@ from testrunner import run def testfunc(child): - child.expect('Initializing APDS99XX sensor') - i = child.expect(['[OK]', '[Failed]']) - if i == 1: - print('FAILED') - return + child.expect_exact('Initializing APDS99XX sensor') + child.expect_exact('[OK]') child.expect(r'ambient = \d+ \[cnts\]') child.expect([r'red = \d+ \[cnts\], green = \d+ \[cnts\], blue = \d+ \[cnts\]', r'illuminance = %d [lux]'])