From 1a987e8f4230e4680f3fbb027c603fb090dbe693 Mon Sep 17 00:00:00 2001 From: Daniel Wallace Date: Fri, 1 Mar 2019 15:38:47 -0600 Subject: [PATCH 1/3] fix flake8 --- pepper/cli.py | 2 +- tests/unit/test_login_details.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/pepper/cli.py b/pepper/cli.py index 07685f6..4d8caa5 100644 --- a/pepper/cli.py +++ b/pepper/cli.py @@ -598,7 +598,7 @@ def login(self, api): logger.error('Login token expired') raise Exception('Login token expired') except Exception as e: - if e.args[0] is not 2: + if e.args[0] != 2: logger.error('Unable to load login token from {0} {1}'.format(token_file, str(e))) if os.path.isfile(token_file): os.remove(token_file) diff --git a/tests/unit/test_login_details.py b/tests/unit/test_login_details.py index 84f5f9e..b1ffca2 100644 --- a/tests/unit/test_login_details.py +++ b/tests/unit/test_login_details.py @@ -20,5 +20,5 @@ def test_interactive_logins(): MagicMock(return_value='pepper') ): result = pepper.cli.PepperCli().get_login_details() - assert result['SALTAPI_USER'] is 'pepper' - assert result['SALTAPI_PASS'] is 'pepper' + assert result['SALTAPI_USER'] == 'pepper' + assert result['SALTAPI_PASS'] == 'pepper' From 2ca42a70d008b817fb27afb03d41ba019e661f6d Mon Sep 17 00:00:00 2001 From: Daniel Wallace Date: Tue, 5 Mar 2019 14:01:14 -0600 Subject: [PATCH 2/3] set tests to use 2018.3 --- tests/requirements.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/requirements.txt b/tests/requirements.txt index a41082f..94e101b 100644 --- a/tests/requirements.txt +++ b/tests/requirements.txt @@ -4,6 +4,6 @@ pytest-rerunfailures pytest-cov git+git://github.com/saltstack/pytest-salt@master#egg=pytest-salt tornado<5.0.0 -salt +salt<2019.2.0 CherryPy setuptools_scm From 3e3f0b4bee051fff3f6ae07cd0d226f67c3338dd Mon Sep 17 00:00:00 2001 From: Daniel Wallace Date: Tue, 5 Mar 2019 18:18:18 -0600 Subject: [PATCH 3/3] pin zeromq to for python3.4 --- tests/requirements.txt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/requirements.txt b/tests/requirements.txt index 94e101b..0e87a0c 100644 --- a/tests/requirements.txt +++ b/tests/requirements.txt @@ -7,3 +7,5 @@ tornado<5.0.0 salt<2019.2.0 CherryPy setuptools_scm +pyzmq>=2.2.0,<17.1.0; python_version == '3.4' # pyzmq 17.1.0 stopped building wheels for python3.4 +pyzmq>=2.2.0; python_version != '3.4'