From 1988de1658c856a61f0f32941ff79049ebe0f5b8 Mon Sep 17 00:00:00 2001 From: sommersoft Date: Fri, 19 Jun 2020 16:17:18 -0500 Subject: [PATCH 1/4] test test test... --- README.rst | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.rst b/README.rst index dfddd133734fb..f4316d7bd4a5e 100644 --- a/README.rst +++ b/README.rst @@ -1,6 +1,8 @@ CircuitPython ============= +Test pytest version 2: now clones the repo for each test, instead of maintaining a static clone... + .. image:: https://s3.amazonaws.com/adafruit-circuit-python/CircuitPython_Repo_header_logo.png |Build Status| |Doc Status| |License| |Discord| |Weblate| From ae766ebccb7d89cf2efc3ecf67d00e1fe9b81809 Mon Sep 17 00:00:00 2001 From: sommersoft Date: Fri, 19 Jun 2020 16:45:14 -0500 Subject: [PATCH 2/4] cpboard.py: missed re-applying repl reset to 'board._reset()' --- tools/cpboard.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tools/cpboard.py b/tools/cpboard.py index 6a5a373f9d109..ddc79843da5af 100644 --- a/tools/cpboard.py +++ b/tools/cpboard.py @@ -492,8 +492,9 @@ def eval(self, expression, timeout=10, reset_repl=False): def _reset(self, mode="NORMAL"): self.exec( - "import microcontroller;microcontroller.on_next_reset(microcontroller.RunMode.%s)" - % mode + "import microcontroller;" + "microcontroller.on_next_reset(microcontroller.RunMode.%s)" % mode, + reset_repl=True ) try: self.exec( From 7f41017b7f3503f9d451e798ee989415d1663f4a Mon Sep 17 00:00:00 2001 From: sommersoft Date: Fri, 19 Jun 2020 23:18:48 -0500 Subject: [PATCH 3/4] test_dev_tests.py: skip metro_m4 vs itsybitsy_m4, so we can see a failed test on physaCI.com --- tests/circuitpython/rosie_tests/rosiepi_dev/test_dev_tests.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/circuitpython/rosie_tests/rosiepi_dev/test_dev_tests.py b/tests/circuitpython/rosie_tests/rosiepi_dev/test_dev_tests.py index 378e2651f1cbe..9d846138736ae 100644 --- a/tests/circuitpython/rosie_tests/rosiepi_dev/test_dev_tests.py +++ b/tests/circuitpython/rosie_tests/rosiepi_dev/test_dev_tests.py @@ -3,7 +3,7 @@ def test_pytest_skip_board(board_name, board, capsys): """ DEV: only used to test skipping by board_name """ - if board_name in ["itsybitsy_m4_express"]: + if board_name in ["metro_m4_express"]: pytest.skip() with board: From ce2754d50cd062cb38d11ba764638dff92eda410 Mon Sep 17 00:00:00 2001 From: sommersoft Date: Sat, 20 Jun 2020 22:00:10 -0500 Subject: [PATCH 4/4] rosie_tests: add basic analogio import test --- .../circuitpython/rosie_tests/analogio/test_analogio.py | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 tests/circuitpython/rosie_tests/analogio/test_analogio.py diff --git a/tests/circuitpython/rosie_tests/analogio/test_analogio.py b/tests/circuitpython/rosie_tests/analogio/test_analogio.py new file mode 100644 index 0000000000000..55ffaee751ab7 --- /dev/null +++ b/tests/circuitpython/rosie_tests/analogio/test_analogio.py @@ -0,0 +1,9 @@ +import pytest + +def test_import(board): + """ Verify import successfully occurs. + """ + with board: + result = board.exec("import analogio") + + assert "importerror" not in result.decode().lower()