From: "Michał Górny" <mgorny@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/pms-test-suite:master commit in: pmstestsuite/library/standard/
Date: Sat, 6 Aug 2011 08:31:09 +0000 (UTC) [thread overview]
Message-ID: <ddaeea47f4a7f3b034ac2db998aedb0cfc3e82cf.mgorny@gentoo> (raw)
commit: ddaeea47f4a7f3b034ac2db998aedb0cfc3e82cf
Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Sat Aug 6 08:02:03 2011 +0000
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Sat Aug 6 08:03:31 2011 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/pms-test-suite.git;a=commit;h=ddaeea47
Add additional checks for dohard & dosed.
---
pmstestsuite/library/standard/banned_commands.py | 27 +++++++++++++++++----
1 files changed, 22 insertions(+), 5 deletions(-)
diff --git a/pmstestsuite/library/standard/banned_commands.py b/pmstestsuite/library/standard/banned_commands.py
index 114089b..456b055 100644
--- a/pmstestsuite/library/standard/banned_commands.py
+++ b/pmstestsuite/library/standard/banned_commands.py
@@ -11,7 +11,7 @@ class BannedCommandTest(DBusEbuildTestCase):
DBusEbuildTestCase.__init__(self, *args, **kwargs)
self._path = '/tmp/pms-test-suite-%d' % id(self)
self.phase_funcs['src_install'].extend([
- 'touch foo || die',
+ '{ echo > foo; } || die',
'insinto %s' % self._path,
'doins foo || die'
])
@@ -22,13 +22,30 @@ class DoHardCommandTest(BannedCommandTest):
def __init__(self, *args, **kwargs):
BannedCommandTest.__init__(self, *args, **kwargs)
- self.phase_funcs['src_install'].append(
- 'dohard %s/foo %s/bar || die' % (self._path, self._path))
+ self.phase_funcs['src_install'].extend([
+ 'dohard %s/foo %s/bar || die' % (self._path, self._path),
+ '[[ "${D}"%s/foo -ef "${D}"%s/bar ]]' % (self._path, self._path),
+ 'pms-test-dbus_append_result ${?}'])
+
+ def check_dbus_result(self, output, pm):
+ try:
+ BannedCommandTest.check_dbus_result(self, output, pm)
+ finally:
+ # XXX: ambiguous in EAPI 4
+ self.assertTrue(output[0] == '0', 'hardlink created')
class DoSedCommandTest(BannedCommandTest):
""" Test whether dosed command is actually banned. """
def __init__(self, *args, **kwargs):
BannedCommandTest.__init__(self, *args, **kwargs)
- self.phase_funcs['src_install'].append(
- 'dosed -e "/11/d" %s/foo || die' % self._path)
+ self.phase_funcs['src_install'].extend([
+ "dosed -e '$i SED WORKED' %s/foo || die" % self._path,
+ 'pms-test-dbus_append_result "$(cat "${D}"%s/foo)"' % self._path])
+
+ def check_dbus_result(self, output, pm):
+ try:
+ BannedCommandTest.check_dbus_result(self, output, pm)
+ finally:
+ # XXX: ambiguous in EAPI 4
+ self.assertEqual(output[0].strip(), 'SED WORKED', 'dosed result')
next reply other threads:[~2011-08-06 8:31 UTC|newest]
Thread overview: 53+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-08-06 8:31 Michał Górny [this message]
-- strict thread matches above, loose matches on Subject: below --
2012-06-20 8:01 [gentoo-commits] proj/pms-test-suite:master commit in: pmstestsuite/library/standard/ Michał Górny
2012-01-03 17:50 Michał Górny
2012-01-03 17:50 Michał Górny
2012-01-03 15:52 Michał Górny
2011-08-13 8:54 Michał Górny
2011-08-12 20:55 Michał Górny
2011-08-08 2:56 Michał Górny
2011-08-07 14:57 Michał Górny
2011-08-07 14:57 Michał Górny
2011-08-07 14:48 Michał Górny
2011-08-06 14:25 Michał Górny
2011-08-06 8:31 Michał Górny
2011-08-05 21:36 Michał Górny
2011-08-05 21:36 Michał Górny
2011-08-05 21:36 Michał Górny
2011-08-05 21:36 Michał Górny
2011-08-05 10:04 Michał Górny
2011-08-05 8:54 Michał Górny
2011-08-03 20:17 Michał Górny
2011-08-03 20:17 Michał Górny
2011-08-03 17:10 Michał Górny
2011-08-03 17:10 Michał Górny
2011-08-03 17:10 Michał Górny
2011-08-03 8:17 Michał Górny
2011-08-02 18:53 Michał Górny
2011-08-02 18:53 Michał Górny
2011-07-28 17:15 Michał Górny
2011-07-27 16:50 Michał Górny
2011-07-27 16:50 Michał Górny
2011-07-27 16:50 Michał Górny
2011-07-26 17:34 Michał Górny
2011-07-24 14:37 Michał Górny
2011-07-24 14:37 Michał Górny
2011-07-18 6:32 Michał Górny
2011-07-18 6:32 Michał Górny
2011-06-29 17:52 Michał Górny
2011-06-29 12:58 Michał Górny
2011-06-28 16:15 Michał Górny
2011-06-28 16:15 Michał Górny
2011-06-25 8:39 Michał Górny
2011-06-24 18:03 [gentoo-commits] proj/pms-test-suite:master commit in: PMSTestSuite/library/standard/ Michał Górny
2011-06-24 18:03 Michał Górny
2011-06-24 18:03 Michał Górny
2011-06-23 21:14 Michał Górny
2011-06-23 21:14 Michał Górny
2011-06-23 9:51 Michał Górny
2011-06-22 19:53 Michał Górny
2011-06-22 13:32 Michał Górny
2011-06-17 14:28 Michał Górny
2011-06-17 14:28 Michał Górny
2011-06-17 14:28 Michał Górny
2011-05-31 19:18 Michał Górny
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=ddaeea47f4a7f3b034ac2db998aedb0cfc3e82cf.mgorny@gentoo \
--to=mgorny@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.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