diff --git a/tests/functional/openlp_core/lib/test_exceptions.py b/tests/functional/openlp_core/lib/test_exceptions.py index 7ffc122c1..c0de323b7 100644 --- a/tests/functional/openlp_core/lib/test_exceptions.py +++ b/tests/functional/openlp_core/lib/test_exceptions.py @@ -42,4 +42,4 @@ class TestValidationError(TestCase): # THEN: Then calling str on the error should return the correct text and it should be an instance of `Exception` assert str(error) == 'Test ValidationError' - assert isinstance(error, Exception) is True + assert isinstance(error, Exception) diff --git a/tests/functional/openlp_core/lib/test_image_manager.py b/tests/functional/openlp_core/lib/test_image_manager.py index 0b37b412d..3c47e81a1 100644 --- a/tests/functional/openlp_core/lib/test_image_manager.py +++ b/tests/functional/openlp_core/lib/test_image_manager.py @@ -98,7 +98,7 @@ class TestImageManager(TestCase, TestMixin): image = self.image_manager.get_image(full_path, 'church.jpg', 80, 80) # THEN: The return should be of type image - assert isinstance(image, QtGui.QImage) is True, 'The returned object should be a QImage' + assert isinstance(image, QtGui.QImage), 'The returned object should be a QImage' # WHEN: adding the same image with different dimensions self.image_manager.add_image(full_path, 'church.jpg', None, 100, 100) diff --git a/tests/functional/openlp_core/lib/test_lib.py b/tests/functional/openlp_core/lib/test_lib.py index 9230ca5b0..7cc44ec4e 100644 --- a/tests/functional/openlp_core/lib/test_lib.py +++ b/tests/functional/openlp_core/lib/test_lib.py @@ -293,7 +293,7 @@ class TestLib(TestCase): # THEN: Check if the thumb was created and scaled to the given size. self.assertTrue(thumb_path.exists(), 'Test was not ran, because the thumb already exists') assert isinstance(icon, QtGui.QIcon), 'The icon should be a QIcon' - assert icon.isNull()is False, 'The icon should not be null' + assert icon.isNull() is False, 'The icon should not be null' assert thumb_size == QtGui.QImageReader(str(thumb_path)).size(), 'The thumb should have the given size' # Remove the thumb so that the test actually tests if the thumb will be created. diff --git a/tests/functional/openlp_core/lib/test_serviceitem.py b/tests/functional/openlp_core/lib/test_serviceitem.py index f07efd2b4..d069f18bf 100644 --- a/tests/functional/openlp_core/lib/test_serviceitem.py +++ b/tests/functional/openlp_core/lib/test_serviceitem.py @@ -113,7 +113,7 @@ class TestServiceItem(TestCase, TestMixin): service_item.set_from_service(line) # THEN: We should get back a valid service item - assert service_item.is_valid, 'The new service item should be valid' + assert service_item.is_valid is True, 'The new service item should be valid' assert_length(0, service_item._display_frames, 'The service item should have no display frames') assert_length(5, service_item.capabilities, 'There should be 5 default custom item capabilities') @@ -334,7 +334,7 @@ class TestServiceItem(TestCase, TestMixin): service_item.set_from_service(line, '/test/') # THEN: We should get back a valid service item - assert service_item.is_valid, 'The new service item should be valid' + assert service_item.is_valid is True, 'The new service item should be valid' assert 0 == len(service_item._display_frames), 'The service item should have no display frames' assert 7 == len(service_item.capabilities), 'There should be 7 default custom item capabilities'