From af37d37e6885b7546c275ef03a459a2cf155caca Mon Sep 17 00:00:00 2001 From: James Barnsley Date: Thu, 6 Feb 2020 16:31:11 +1300 Subject: [PATCH] Moving through unit tests, still failing --- .coverage | Bin 53248 -> 53248 bytes mopidy_iris/system.py | 7 +++---- setup.cfg | 42 ++++++++++++++++++++++++++++++++---------- tox.ini | 19 ++----------------- 4 files changed, 37 insertions(+), 31 deletions(-) diff --git a/.coverage b/.coverage index 206ed31aae03645d8de515335f818891db5b5e96..1eb6ab9c9323fc4397806162cf83c4c26abf7c21 100644 GIT binary patch delta 403 zcmZozz}&Ead4e<}-$WT_M!t;+%jCH@82Fv}jrhg*IW`Ll{NS4`t*@YDreI)fWo%$& zYRb>VEG=G^T2!2wpJ%FPpl94@#mFMtlsP$8e}PCzYH>-iK8TDjt}HG|&DATY-26|U zSAcUL{~Z2${#br{pqbkI3NmcW4EFk&MVZC=x%mZ|DV6bHc5;4EDo~38>tsiN1tw{h z$qW5u7@2__QQfqn{JfIXycD3c91}BxGp1&^jS7q)9h1NMi*Y*e&*hKfZ{Xh#v{r{- zPL|o85mO`7R<_9w@rsPBlNZFxFtPyIVj4(xGRreNW6=t+bMx(ZO$81n{<{qPpZV_s zt-8psFT%va$f?C-H*@RF_gC9^EBF`~-p*#_W@O>ylnP^vWfEZE;9_84VB-J6!2g^7 P3sBPw{>@+J^B4dCN3(j3 delta 556 zcmX|7Jxd%>6us|b9y6ov9hXFjGwLX!h_bs`wXx6<6CyU#nL>0_R1{6ShrAiu?${A{G(?A*6_1VAng(jkkE`zVptx=kn6JNbBOA&)oB1k+~l?-VeGy z;0nIPar7JAUI%Ks7!J>b<>#~0rP=Z{a^d&B**QMhKdj6YN`bduj7(a!_OFD9k*!EB^@K|X?ZKwUh5N$p*7sc}yc}A_d3+qD!z%rIsd!)sj z+N5l@R&W1ING@#%!2@p7tCvXtvX=BA$qDW3JbMT=0vlusDMaK0a{n*7MeUyU$kIHb zXxAtuFzJM*BC?zE+F6urD?!`lgzIp^Cw%VNQoe&p$LU*PYrK~PE?E>_0sg}~{Ea{G bJ6_S}e8V978>W;2%Q7IP0U;W9mz|}1suyAT diff --git a/mopidy_iris/system.py b/mopidy_iris/system.py index a3809712..868e3016 100755 --- a/mopidy_iris/system.py +++ b/mopidy_iris/system.py @@ -17,9 +17,8 @@ class IrisSystemPermissionError(IrisSystemError): def __init__(self, path): message = ( - r"""Password-less access to %s was refused. - Check your /etc/sudoers file.""" - % path.as_uri() + "Password-less access to %s was refused. " + "Check your /etc/sudoers file." % path.as_uri() ) logger.error(message) super().__init__(message) @@ -61,7 +60,7 @@ class IrisSystemThread(Thread): except IrisSystemError as e: logger.error(e) - error = {"message": e.reason, "description": e.message} + error = {"message": e.reason, "description": str(e)} return {"error": error} diff --git a/setup.cfg b/setup.cfg index e1e52069..9cfe14d3 100755 --- a/setup.cfg +++ b/setup.cfg @@ -83,16 +83,16 @@ ignore = # B305: .next() is not a thing on Python 3 (used by playback controller) B305 exclude = - .circleci, - .git, - .tox, - .vscode, - docs, - tests, - src, - node_modules, - build_tools, - docker, + .circleci + .git + .tox + .vscode + docs + tests + src + node_modules + build_tools + docker Screenshots [check-manifest] @@ -103,6 +103,8 @@ ignore = docker/* Screenshots Screenshots/* + node_modules + node_modules/* src src/* .circleci @@ -111,4 +113,24 @@ ignore = .htaccess .vscode .vscode/* + .dockerignore + +[tool:pytest] +norecursedirs = + build_tools + build_tools/* + docker + docker/* + Screenshots + Screenshots/* + src + src/* + node_modules + node_modules/* + .circleci + .circleci/* + .dockerignore + .htaccess + .vscode + .vscode/* .dockerignore \ No newline at end of file diff --git a/tox.ini b/tox.ini index 0652ae21..db319b31 100755 --- a/tox.ini +++ b/tox.ini @@ -1,5 +1,6 @@ [tox] -envlist = py37, py38, black, check-manifest, flake8 +envlist = py37 +#envlist = py37, py38, black, check-manifest, flake8 [testenv] sitepackages = true @@ -17,22 +18,6 @@ commands = python -m black --check . [testenv:check-manifest] deps = .[lint] commands = python -m check_manifest -ignore = - build_tools - build_tools/* - docker - docker/* - Screenshots - Screenshots/* - src - src/* - .circleci - .circleci/* - .dockerignore - .htaccess - .vscode - .vscode/* - .dockerignore [testenv:flake8] deps = .[lint]