summaryrefslogtreecommitdiff
path: root/gitlab/tests/test_config.py
diff options
context:
space:
mode:
authorJohn L. Villalovos <john@sodarock.com>2021-04-17 14:10:41 -0700
committerJohn L. Villalovos <john@sodarock.com>2021-04-18 07:13:47 -0700
commit630901b30911af01da5543ca609bd27bc5a1a44c (patch)
tree38ae7cfe09cdceca0673834f0c4ff0a9ca6a9813 /gitlab/tests/test_config.py
parent83670a49a3affd2465f8fcbcc3c26141592c1ccd (diff)
downloadgitlab-630901b30911af01da5543ca609bd27bc5a1a44c.tar.gz
chore: fix E711 error reported by flake8
E711: Comparison to none should be 'if cond is none:' https://www.flake8rules.com/rules/E711.html
Diffstat (limited to 'gitlab/tests/test_config.py')
-rw-r--r--gitlab/tests/test_config.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/gitlab/tests/test_config.py b/gitlab/tests/test_config.py
index e428cd1..b456cff 100644
--- a/gitlab/tests/test_config.py
+++ b/gitlab/tests/test_config.py
@@ -154,7 +154,7 @@ def test_valid_data(m_open, path_exists):
assert "one" == cp.gitlab_id
assert "http://one.url" == cp.url
assert "ABCDEF" == cp.private_token
- assert None == cp.oauth_token
+ assert cp.oauth_token is None
assert 2 == cp.timeout
assert cp.ssl_verify is True
assert cp.per_page is None
@@ -166,7 +166,7 @@ def test_valid_data(m_open, path_exists):
assert "two" == cp.gitlab_id
assert "https://two.url" == cp.url
assert "GHIJKL" == cp.private_token
- assert None == cp.oauth_token
+ assert cp.oauth_token is None
assert 10 == cp.timeout
assert cp.ssl_verify is False
@@ -177,7 +177,7 @@ def test_valid_data(m_open, path_exists):
assert "three" == cp.gitlab_id
assert "https://three.url" == cp.url
assert "MNOPQR" == cp.private_token
- assert None == cp.oauth_token
+ assert cp.oauth_token is None
assert 2 == cp.timeout
assert "/path/to/CA/bundle.crt" == cp.ssl_verify
assert 50 == cp.per_page
@@ -188,7 +188,7 @@ def test_valid_data(m_open, path_exists):
cp = config.GitlabConfigParser(gitlab_id="four")
assert "four" == cp.gitlab_id
assert "https://four.url" == cp.url
- assert None == cp.private_token
+ assert cp.private_token is None
assert "STUV" == cp.oauth_token
assert 2 == cp.timeout
assert cp.ssl_verify is True
@@ -227,7 +227,7 @@ def test_data_from_helper(m_open, path_exists, tmp_path):
cp = config.GitlabConfigParser(gitlab_id="helper")
assert "helper" == cp.gitlab_id
assert "https://helper.url" == cp.url
- assert None == cp.private_token
+ assert cp.private_token is None
assert "secret" == cp.oauth_token