From 762d3acb93c597b5299864f9b3ee551107978ee2 Mon Sep 17 00:00:00 2001 From: Tim Hall Date: Thu, 6 Jul 2023 11:42:02 +0100 Subject: MLBEDSW-7832: test_tflite_model_semantic converting array to scalar - The problem is that the axis value can be either a scalar or an array containing a single element - The solution is to check the length of the shape because the size attribute returns the same value for both cases - This did not show up before because pytest warnings were not being treated as errors - Removed pre-commit pytest option that caused tests to be searched for from the root directory - Updated pyproject.toml pytest options to explicitly specify the test directories, and to treat warnings as errors Change-Id: I037054768e5c34f253b6062eadba1c3419ff65e4 --- pyproject.toml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'pyproject.toml') diff --git a/pyproject.toml b/pyproject.toml index 2127d1ab..f2c5d60f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -62,4 +62,11 @@ requires = [ "numpy; python_version>'3.7'", "setuptools_scm[toml]~=7.1.0" ] -build-backend = "setuptools.build_meta" \ No newline at end of file +build-backend = "setuptools.build_meta" + +[tool.pytest.ini_options] +minversion = "6.0" +addopts = ["-ra", "--showlocals", "--strict-markers", "--strict-config"] +xfail_strict = true +filterwarnings = ["error"] +testpaths = ["ethosu/mlw_codec/test", "ethosu/vela/test"] \ No newline at end of file -- cgit v1.2.1