From 376fc21f92e9faf01d582a3e4c4948e5f198cc1d Mon Sep 17 00:00:00 2001 From: Michael Scherer Date: Tue, 17 May 2016 02:00:21 +0200 Subject: [PATCH] Add a exception for module_utils/six.py regarding code smell (#15878) Since six replace urlopen, it is normal to trigger the test, hence the exception --- test/code-smell/replace-urlopen.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/code-smell/replace-urlopen.sh b/test/code-smell/replace-urlopen.sh index 725bcab4d3..3973ca64b1 100755 --- a/test/code-smell/replace-urlopen.sh +++ b/test/code-smell/replace-urlopen.sh @@ -3,7 +3,7 @@ BASEDIR=${1-"."} URLLIB_USERS=$(find "$BASEDIR" -name '*.py' -exec grep -H urlopen \{\} \;) -URLLIB_USERS=$(echo "$URLLIB_USERS" | sed '/\(\n\|lib\/ansible\/module_utils\/urls.py\|lib\/ansible\/compat\/six\/_six.py\|.tox\)/d') +URLLIB_USERS=$(echo "$URLLIB_USERS" | sed '/\(\n\|lib\/ansible\/module_utils\/urls.py\|lib\/ansible\/module_utils\/six.py\|lib\/ansible\/compat\/six\/_six.py\|.tox\)/d') URLLIB_USERS=$(echo "$URLLIB_USERS" | sed '/^[^:]\+:#/d') if test -n "$URLLIB_USERS" ; then printf "$URLLIB_USERS"