From f4cc3b79980c4d9b5a4485f38e354b62811dd52c Mon Sep 17 00:00:00 2001 From: Laurent Pinchart Date: Fri, 10 Jun 2022 01:14:59 +0300 Subject: tests: Replace double quotes with single quotes The code base mixes single and double quotes. Standardize on single quotes except for triple-quoted strings (to match the PEP8 coding style) and where the string contains single quotes to avoid the need to escape them. Signed-off-by: Laurent Pinchart Reviewed-by: Kieran Bingham --- tests/kms-test-allplanes.py | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'tests/kms-test-allplanes.py') diff --git a/tests/kms-test-allplanes.py b/tests/kms-test-allplanes.py index d883262..710ae66 100755 --- a/tests/kms-test-allplanes.py +++ b/tests/kms-test-allplanes.py @@ -9,7 +9,7 @@ class AllPlanesTest(kmstest.KMSTest): """Test composition with all planes enabled on all CRTCs.""" def handle_page_flip(self, frame, time): - self.logger.log("Page flip complete") + self.logger.log('Page flip complete') def main(self): # Create the connectors to CRTCs map @@ -25,14 +25,14 @@ class AllPlanesTest(kmstest.KMSTest): connectors[crtc] = connector for crtc in self.card.crtcs: - self.start("composition on CRTC %u" % crtc.id) + self.start('composition on CRTC %u' % crtc.id) # Get the connector and default mode try: connector = connectors[crtc]; mode = connector.get_default_mode() except KeyError: - self.skip("no connector or mode available") + self.skip('no connector or mode available') continue # List planes available for the CRTC @@ -42,20 +42,20 @@ class AllPlanesTest(kmstest.KMSTest): planes.append(plane) if len(planes) == 0: - self.skip("no plane available for CRTC") + self.skip('no plane available for CRTC') continue - self.logger.log("Testing connector %s, CRTC %u, mode %s with %u planes" % \ + self.logger.log('Testing connector %s, CRTC %u, mode %s with %u planes' % \ (connector.fullname, crtc.id, mode.name, len(planes))) # Create a frame buffer - fb = pykms.DumbFramebuffer(self.card, mode.hdisplay, mode.vdisplay, "XR24") + fb = pykms.DumbFramebuffer(self.card, mode.hdisplay, mode.vdisplay, 'XR24') pykms.draw_test_pattern(fb) # Set the mode with a primary plane ret = self.atomic_crtc_mode_set(crtc, connector, mode, fb) if ret < 0: - self.fail("atomic mode set failed with %d" % ret) + self.fail('atomic mode set failed with %d' % ret) continue self.run(3) @@ -67,14 +67,14 @@ class AllPlanesTest(kmstest.KMSTest): destination = kmstest.Rect(offset, offset, fb.width, fb.height) ret = self.atomic_plane_set(plane, crtc, source, destination, fb) if ret < 0: - self.fail("atomic plane set failed with %d" % ret) + self.fail('atomic plane set failed with %d' % ret) break - self.logger.log("Adding plane %u" % plane.id) + self.logger.log('Adding plane %u' % plane.id) self.run(1) if self.flips == 0: - self.fail("No page flip registered") + self.fail('No page flip registered') break offset += 50 -- cgit v1.2.3