|
@@ -990,6 +990,26 @@ class Wic2(WicTestCase):
|
|
|
out = glob(self.resultdir + "%s-*direct" % wksname)
|
|
|
self.assertEqual(1, len(out))
|
|
|
|
|
|
+ def test_empty_plugin(self):
|
|
|
+ """Test empty plugin"""
|
|
|
+ config = 'IMAGE_FSTYPES = "wic"\nWKS_FILE = "test_empty_plugin.wks"\n'
|
|
|
+ self.append_config(config)
|
|
|
+ self.assertEqual(0, bitbake('core-image-minimal').status)
|
|
|
+ self.remove_config(config)
|
|
|
+
|
|
|
+ bb_vars = get_bb_vars(['DEPLOY_DIR_IMAGE', 'MACHINE'])
|
|
|
+ deploy_dir = bb_vars['DEPLOY_DIR_IMAGE']
|
|
|
+ machine = bb_vars['MACHINE']
|
|
|
+ image_path = os.path.join(deploy_dir, 'core-image-minimal-%s.wic' % machine)
|
|
|
+ self.assertEqual(True, os.path.exists(image_path))
|
|
|
+
|
|
|
+ sysroot = get_bb_var('RECIPE_SYSROOT_NATIVE', 'wic-tools')
|
|
|
+
|
|
|
+ # Fstype column from 'wic ls' should be empty for the second partition
|
|
|
+ # as listed in test_empty_plugin.wks
|
|
|
+ result = runCmd("wic ls %s -n %s | awk -F ' ' '{print $1 \" \" $5}' | grep '^2' | wc -w" % (image_path, sysroot))
|
|
|
+ self.assertEqual('1', result.output)
|
|
|
+
|
|
|
@only_for_arch(['i586', 'i686', 'x86_64'])
|
|
|
def test_biosplusefi_plugin_qemu(self):
|
|
|
"""Test biosplusefi plugin in qemu"""
|