summaryrefslogtreecommitdiff
path: root/tests/test_aptsources.py
diff options
context:
space:
mode:
authorJulian Andres Klode <jak@debian.org>2014-01-06 12:17:44 +0100
committerJulian Andres Klode <jak@debian.org>2014-01-06 12:21:28 +0100
commitd95a8f27774842beb43bda54c4c61b67fe76a032 (patch)
tree2db8a964a440fb7d19759b39c7cd0de5b5b7c803 /tests/test_aptsources.py
parent3bf9c3fe4d19ed4d985dc8b7747a737699f46a7e (diff)
downloadpython-apt-d95a8f27774842beb43bda54c4c61b67fe76a032.tar.gz
Style fix: Do not use "is True" / "is False"
This is uncommon style. It's better to use "pred" instead of "pred is True" and "not pred" instead of "pred is False".
Diffstat (limited to 'tests/test_aptsources.py')
-rw-r--r--tests/test_aptsources.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/test_aptsources.py b/tests/test_aptsources.py
index 4539b2d1..e6d0bd82 100644
--- a/tests/test_aptsources.py
+++ b/tests/test_aptsources.py
@@ -149,14 +149,14 @@ class TestAptSources(unittest.TestCase):
apt_pkg.config.set("Dir::Etc::sourcelist", "data/aptsources/"
"sources.list")
sources = aptsources.sourceslist.SourcesList(True, self.templates)
- assert sources.list[8].invalid is False
+ assert not sources.list[8].invalid
assert sources.list[8].type == "deb"
assert sources.list[8].architectures == ["amd64", "i386"]
assert sources.list[8].uri == "http://de.archive.ubuntu.com/ubuntu/"
assert sources.list[8].dist == "natty"
assert sources.list[8].comps == ["main"]
assert sources.list[8].line.strip() == str(sources.list[8])
- assert sources.list[8].trusted is None
+ assert not sources.list[8].trusted
def testMultipleOptions(self):
"""aptsources: Test multi-arch parsing"""