From: Ed Bartosh <ed.bartosh@linux.intel.com>
To: openembedded-core@lists.openembedded.org
Subject: [PATCH 2/9] oe-selftest: add wic test case test_fs_types
Date: Tue, 28 Mar 2017 15:40:59 +0300 [thread overview]
Message-ID: <a850489583522e2b43ca220a566ea40468e49dae.1490704390.git.ed.bartosh@linux.intel.com> (raw)
In-Reply-To: <cover.1490704390.git.ed.bartosh@linux.intel.com>
Added wic test case to test all possible filesystem
types for empty and not empty partitions.
[YOCTO #10618]
Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com>
---
meta/lib/oeqa/selftest/wic.py | 19 +++++++++++++++++++
1 file changed, 19 insertions(+)
diff --git a/meta/lib/oeqa/selftest/wic.py b/meta/lib/oeqa/selftest/wic.py
index ee633f8..2af3bf5 100644
--- a/meta/lib/oeqa/selftest/wic.py
+++ b/meta/lib/oeqa/selftest/wic.py
@@ -717,3 +717,22 @@ part /etc --source rootfs --ondisk mmcblk0 --fstype=ext4 --exclude-path bin/ --r
wksname = os.path.splitext(os.path.basename(wks.name))[0]
out = glob(self.resultdir + "%s-*direct" % wksname)
self.assertEqual(1, len(out))
+
+ def test_fs_types(self):
+ """Test filesystem types for empty and not empty partitions"""
+ img = 'core-image-minimal'
+ with NamedTemporaryFile("w", suffix=".wks") as wks:
+ wks.writelines(['part ext2 --fstype ext2 --source rootfs\n',
+ 'part btrfs --fstype btrfs --source rootfs --size 40M\n',
+ 'part squash --fstype squashfs --source rootfs\n',
+ 'part swap --fstype swap --size 1M\n',
+ 'part emptyvfat --fstype vfat --size 1M\n',
+ 'part emptyext2 --fstype ext2 --size 1M\n',
+ 'part emptybtrfs --fstype btrfs --size 100M\n',
+ 'part emptysquash --fstype squash --size 1M\n'])
+ wks.flush()
+ cmd = "wic create %s -e %s -o %s" % (wks.name, img, self.resultdir)
+ self.assertEqual(0, runCmd(cmd).status)
+ wksname = os.path.splitext(os.path.basename(wks.name))[0]
+ out = glob(self.resultdir + "%s-*direct" % wksname)
+ self.assertEqual(1, len(out))
--
2.1.4
next prev parent reply other threads:[~2017-03-28 12:43 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-28 12:40 [PATCH 0/9] #10618: Increase oe-selftest coverage of wic codebase (last part) Ed Bartosh
2017-03-28 12:40 ` [PATCH 1/9] wic-tools: add btrfs-tools squashfs-tools to DEPENDS Ed Bartosh
2017-03-28 12:40 ` Ed Bartosh [this message]
2017-03-28 12:41 ` [PATCH 3/9] filemap: remove FilemapSeek class Ed Bartosh
2017-03-28 12:41 ` [PATCH 4/9] oe-selftest: add kickstart_parser test case Ed Bartosh
2017-03-28 12:41 ` [PATCH 5/9] wic: remove fsimage plugin Ed Bartosh
2017-03-28 12:41 ` [PATCH 6/9] wic: use wic-tools STAGING_DATADIR as bootimg_dir Ed Bartosh
2017-03-28 12:41 ` [PATCH 7/9] wic: remove runner.show API Ed Bartosh
2017-03-28 12:41 ` [PATCH 8/9] wic: remove unused code from runner module Ed Bartosh
2017-03-28 12:41 ` [PATCH 9/9] oe-selftest: add test_image_bootpart_globbed test for wic Ed Bartosh
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=a850489583522e2b43ca220a566ea40468e49dae.1490704390.git.ed.bartosh@linux.intel.com \
--to=ed.bartosh@linux.intel.com \
--cc=openembedded-core@lists.openembedded.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox