diff mbox

[Branch,~linaro-image-tools/linaro-image-tools/trunk] Rev 630: PEP8 fixes.

Message ID 20130729102035.22262.21422.launchpad@ackee.canonical.com
State Accepted
Headers show

Commit Message

Milo Casagrande July 29, 2013, 10:20 a.m. UTC
Merge authors:
  Milo Casagrande (milo)
Related merge proposals:
  https://code.launchpad.net/~milo/linaro-image-tools/pep8-fixes/+merge/176891
  proposed by: Milo Casagrande (milo)
------------------------------------------------------------
revno: 630 [merge]
committer: Milo Casagrande <milo@ubuntu.com>
branch nick: trunk
timestamp: Thu 2013-07-25 10:05:43 +0200
message:
  PEP8 fixes.
modified:
  linaro_image_tools/hwpack/tests/test_config_v3.py
  linaro_image_tools/media_create/boards.py
  linaro_image_tools/media_create/tests/test_media_create.py


--
lp:linaro-image-tools
https://code.launchpad.net/~linaro-image-tools/linaro-image-tools/trunk

You are subscribed to branch lp:linaro-image-tools.
To unsubscribe from this branch go to https://code.launchpad.net/~linaro-image-tools/linaro-image-tools/trunk/+edit-subscription
diff mbox

Patch

=== modified file 'linaro_image_tools/hwpack/tests/test_config_v3.py'
--- linaro_image_tools/hwpack/tests/test_config_v3.py	2013-02-17 13:53:41 +0000
+++ linaro_image_tools/hwpack/tests/test_config_v3.py	2013-07-25 08:00:25 +0000
@@ -853,7 +853,7 @@ 
                      ' - adest.dtb : boot/dt-*-linaro-omap/omap4-panda.dtb\n' +
                      ' - bdest.dtb : ' +
                      'boot/dt-*-linaro-omap2/omap4-panda2.dtb\n')
-        expected = [{'adest.dtb':'boot/dt-*-linaro-omap/omap4-panda.dtb'},
+        expected = [{'adest.dtb': 'boot/dt-*-linaro-omap/omap4-panda.dtb'},
                     {'bdest.dtb': 'boot/dt-*-linaro-omap2/omap4-panda2.dtb'}]
         config = self.get_config(self.valid_complete_v3 + dtb_files)
         config.validate()

=== modified file 'linaro_image_tools/media_create/boards.py'
--- linaro_image_tools/media_create/boards.py	2013-06-28 13:09:08 +0000
+++ linaro_image_tools/media_create/boards.py	2013-07-25 08:00:25 +0000
@@ -1533,14 +1533,14 @@ 
             seek=self.samsung_env_start)
         # Populate created raw partition with BL1 and u-boot
         spl_file = os.path.join(chroot_dir, 'boot', 'u-boot-mmc-spl.bin')
-        assert os.path.getsize(spl_file) <= (
-            self.samsung_bl1_len * SECTOR_SIZE), (
-                "%s is larger than Samsung BL1 size" % spl_file)
+        assert os.path.getsize(spl_file) <= \
+            (self.samsung_bl1_len * SECTOR_SIZE), \
+            ("%s is larger than Samsung BL1 size" % spl_file)
         _dd(spl_file, boot_device_or_file, seek=self.samsung_bl1_start)
         uboot_file = os.path.join(chroot_dir, 'boot', 'u-boot.bin')
-        assert os.path.getsize(uboot_file) <= (
-            self.samsung_bl2_len * SECTOR_SIZE), (
-                "%s is larger than Samsung BL2 size" % uboot_file)
+        assert os.path.getsize(uboot_file) <= \
+            (self.samsung_bl2_len * SECTOR_SIZE), \
+            ("%s is larger than Samsung BL2 size" % uboot_file)
         _dd(uboot_file, boot_device_or_file, seek=self.samsung_bl2_start)
 
 

=== modified file 'linaro_image_tools/media_create/tests/test_media_create.py'
--- linaro_image_tools/media_create/tests/test_media_create.py	2013-06-27 09:04:20 +0000
+++ linaro_image_tools/media_create/tests/test_media_create.py	2013-07-25 08:00:25 +0000
@@ -848,11 +848,12 @@ 
             ('sudo -E dd if=%s of=boot_device_or_file bs=512 conv=notrunc '
              'seek=1' % bl0_file),
             ('sudo -E mkimage -A arm -O linux -T kernel -C none -a %s -e %s '
-             '-n Linux -d %s %s/uImage' % (board_conf.load_addr,
-             board_conf.load_addr, k_img_file, self.temp_bootdir_path)),
+             '-n Linux -d %s %s/uImage'
+             % (board_conf.load_addr, board_conf.load_addr,
+                k_img_file, self.temp_bootdir_path)),
             ('sudo -E mkimage -A arm -O linux -T ramdisk -C none -a 0 -e 0 '
-             '-n initramfs -d %s %s/uInitrd' % (
-             i_img_file, self.temp_bootdir_path))]
+             '-n initramfs -d %s %s/uInitrd'
+             % (i_img_file, self.temp_bootdir_path))]
         self.assertEqual(expected_commands,
                          popen_fixture.mock.commands_executed)
         shutil.rmtree(self.tempdir)
@@ -1077,7 +1078,7 @@ 
         expected = [
             '%s dd if=%s of=boot_device_or_file bs=512 conv=notrunc'
             ' seek=%s' % (sudo_args, toc_filename,
-            self.snowball_config.SNOWBALL_LOADER_START_S),
+                          self.snowball_config.SNOWBALL_LOADER_START_S),
             '%s dd if=%s/boot_image_issw.bin of=boot_device_or_file bs=512'
             ' conv=notrunc seek=257' % (sudo_args, self.temp_bootdir_path),
             '%s dd if=%s/boot_image_x-loader.bin of=boot_device_or_file'
@@ -1105,23 +1106,23 @@ 
         expected = [
             '%s dd if=%s of=boot_device_or_file bs=512 conv=notrunc'
             ' seek=%s' % (sudo_args, toc_filename,
-            self.snowball_config.SNOWBALL_LOADER_START_S),
+                          self.snowball_config.SNOWBALL_LOADER_START_S),
             '%s dd if=%s/boot_image_issw.bin of=boot_device_or_file bs=512'
             ' conv=notrunc seek=257' % (sudo_args, self.temp_bootdir_path),
             '%s rm %s/boot_image_issw.bin' % (sudo_args,
-            self.temp_bootdir_path),
+                                              self.temp_bootdir_path),
             '%s dd if=%s/boot_image_x-loader.bin of=boot_device_or_file'
             ' bs=1 conv=notrunc seek=131588'
             % (sudo_args, self.temp_bootdir_path),
             '%s rm %s/boot_image_x-loader.bin' % (sudo_args,
-            self.temp_bootdir_path),
+                                                  self.temp_bootdir_path),
             '%s dd if=%s/mem_init.bin of=boot_device_or_file bs=512'
             ' conv=notrunc seek=3072' % (sudo_args, self.temp_bootdir_path),
             '%s rm %s/mem_init.bin' % (sudo_args, self.temp_bootdir_path),
             '%s dd if=%s/power_management.bin of=boot_device_or_file bs=512'
             ' conv=notrunc seek=3200' % (sudo_args, self.temp_bootdir_path),
             '%s rm %s/power_management.bin' % (sudo_args,
-            self.temp_bootdir_path),
+                                               self.temp_bootdir_path),
             '%s dd if=%s/u-boot.bin of=boot_device_or_file bs=512'
             ' conv=notrunc seek=24064' % (sudo_args, self.temp_bootdir_path),
             '%s rm %s/u-boot.bin' % (sudo_args, self.temp_bootdir_path),
@@ -1142,7 +1143,7 @@ 
         expected = [
             '%s dd if=%s of=boot_device_or_file bs=512 conv=notrunc'
             ' seek=%s' % (sudo_args, toc_filename,
-            board_conf.SNOWBALL_LOADER_START_S),
+                          board_conf.SNOWBALL_LOADER_START_S),
             '%s dd if=%s/boot_image_issw.bin of=boot_device_or_file bs=512'
             ' conv=notrunc seek=257' % (sudo_args, self.temp_bootdir_path),
             '%s dd if=%s/boot_image_x-loader.bin of=boot_device_or_file'
@@ -1179,8 +1180,8 @@ 
                                               k_img_file, i_img_file, None)
         expected = [
             '%s mkimage -A arm -O linux -T kernel -C none -a 0x00008000 -e'
-            ' 0x00008000 -n Linux -d %s %s/boot/uImage' % (sudo_args,
-            k_img_file, self.tempdir),
+            ' 0x00008000 -n Linux -d %s %s/boot/uImage'
+            % (sudo_args, k_img_file, self.tempdir),
             '%s cp /tmp/temp_snowball_make_boot_files %s/boot/boot.txt'
             % (sudo_args, self.tempdir),
             '%s mkimage -A arm -O linux -T script -C none -a 0 -e 0 -n boot'
@@ -1192,18 +1193,18 @@ 
             '%s dd if=%s/boot/boot_image_issw.bin of=boot_device_or_file'
             ' bs=512 conv=notrunc seek=257' % (sudo_args, self.tempdir),
             '%s rm %s/boot_image_issw.bin' % (sudo_args,
-            self.temp_bootdir_path),
+                                              self.temp_bootdir_path),
             '%s dd if=%s/boot/boot_image_x-loader.bin of=boot_device_or_file'
             ' bs=1 conv=notrunc seek=131588' % (sudo_args, self.tempdir),
             '%s rm %s/boot_image_x-loader.bin' % (sudo_args,
-            self.temp_bootdir_path),
+                                                  self.temp_bootdir_path),
             '%s dd if=%s/boot/mem_init.bin of=boot_device_or_file bs=512'
             ' conv=notrunc seek=3072' % (sudo_args, self.tempdir),
             '%s rm %s/mem_init.bin' % (sudo_args, self.temp_bootdir_path),
             '%s dd if=%s/boot/power_management.bin of=boot_device_or_file'
             ' bs=512 conv=notrunc seek=3200' % (sudo_args, self.tempdir),
             '%s rm %s/power_management.bin' % (sudo_args,
-            self.temp_bootdir_path),
+                                               self.temp_bootdir_path),
             '%s dd if=%s/boot/u-boot.bin of=boot_device_or_file bs=512'
             ' conv=notrunc seek=24064' % (sudo_args, self.tempdir),
             '%s rm %s/u-boot.bin' % (sudo_args, self.temp_bootdir_path),