From patchwork Wed Apr 22 15:52:54 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Heinrich Schuchardt X-Patchwork-Id: 238326 List-Id: U-Boot discussion From: xypron.glpk at gmx.de (Heinrich Schuchardt) Date: Wed, 22 Apr 2020 17:52:54 +0200 Subject: [PATCH 1/2] test/py: efi_secboot should not assume sbin is in the path In-Reply-To: <20200422155255.148711-1-xypron.glpk@gmx.de> References: <20200422155255.148711-1-xypron.glpk@gmx.de> Message-ID: <20200422155255.148711-2-xypron.glpk@gmx.de> For non-root users /sbin is typically not in the path. So use absolute paths to mkfs.vfat and sgdisk. Signed-off-by: Heinrich Schuchardt --- test/py/tests/test_efi_secboot/conftest.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) -- 2.26.1 diff --git a/test/py/tests/test_efi_secboot/conftest.py b/test/py/tests/test_efi_secboot/conftest.py index e542fef6e8..40cdf15bf2 100644 --- a/test/py/tests/test_efi_secboot/conftest.py +++ b/test/py/tests/test_efi_secboot/conftest.py @@ -48,12 +48,12 @@ def efi_boot_env(request, u_boot_config): # create a disk/partition check_call('dd if=/dev/zero of=%s bs=1MiB count=%d' % (image_path, image_size), shell=True) - check_call('sgdisk %s -n 1:0:+%dMiB' + check_call('/sbin/sgdisk %s -n 1:0:+%dMiB' % (image_path, part_size), shell=True) # create a file system check_call('dd if=/dev/zero of=%s.tmp bs=1MiB count=%d' % (image_path, part_size), shell=True) - check_call('mkfs -t %s %s.tmp' % (fs_type, image_path), shell=True) + check_call('/sbin/mkfs.%s %s.tmp' % (fs_type, image_path), shell=True) check_call('dd if=%s.tmp of=%s bs=1MiB seek=1 count=%d conv=notrunc' % (image_path, image_path, 1), shell=True) check_call('rm %s.tmp' % image_path, shell=True)