[ovs-dev] [PATCHv3 2/2] ovs-dev.py: Add option to run tests in parallel.
Joe Stringer
joestringer at nicira.com
Wed Jun 4 02:15:58 UTC 2014
Thanks, I applied this with the following incremental:
diff --git a/utilities/ovs-dev.py b/utilities/ovs-dev.py
index fa74d57..efc65c8 100755
--- a/utilities/ovs-dev.py
+++ b/utilities/ovs-dev.py
@@ -145,8 +145,8 @@ commands.append(make)
def check():
flags = ""
- if options.parallel:
- flags += "-j%d " % options.parallel
+ if options.jobs:
+ flags += "-j%d " % options.jobs
else:
flags += "-j8 "
if options.tests:
@@ -368,7 +368,7 @@ def main():
parser.add_option_group(group)
group = optparse.OptionGroup(parser, "check")
- group.add_option("-p", dest="parallel", metavar="N_TESTS", type="int",
- help="Run N_TESTS in parallel")
+ group.add_option("-j", "--jobs", dest="jobs", metavar="N", type="int",
+ help="Run N tests in parallel")
group.add_option("--tests", dest="tests", metavar="FILTER",
help="""run specific tests and/or a test category
On 4 June 2014 12:45, Ethan Jackson <ethan at nicira.com> wrote:
> Sorry to nit pick, but could we change the option name to "--jobs" and
> the abbreviated option to "-j". This is consistent with how make does
> it.
>
> Acked-by: Ethan Jackson <ethan at nicira.com>
>
>
> On Tue, Jun 3, 2014 at 5:41 PM, Joe Stringer <joestringer at nicira.com>
> wrote:
> > Signed-off-by: Joe Stringer <joestringer at nicira.com>
> > ---
> > v3: Set the default to -j8.
> > v2: Make it configurable.
> > v1: First post.
> > ---
> > utilities/ovs-dev.py | 6 ++++++
> > 1 file changed, 6 insertions(+)
> >
> > diff --git a/utilities/ovs-dev.py b/utilities/ovs-dev.py
> > index 2c3af19..fa74d57 100755
> > --- a/utilities/ovs-dev.py
> > +++ b/utilities/ovs-dev.py
> > @@ -145,6 +145,10 @@ commands.append(make)
> >
> > def check():
> > flags = ""
> > + if options.parallel:
> > + flags += "-j%d " % options.parallel
> > + else:
> > + flags += "-j8 "
> > if options.tests:
> > for arg in str.split(options.tests):
> > if arg[0].isdigit():
> > @@ -364,6 +368,8 @@ def main():
> > parser.add_option_group(group)
> >
> > group = optparse.OptionGroup(parser, "check")
> > + group.add_option("-p", dest="parallel", metavar="N_TESTS",
> type="int",
> > + help="Run N_TESTS in parallel")
> > group.add_option("--tests", dest="tests", metavar="FILTER",
> > help="""run specific tests and/or a test category
> > eg, --tests=\"1-10 megaflow\"""")
> > --
> > 1.7.10.4
> >
> > _______________________________________________
> > dev mailing list
> > dev at openvswitch.org
> > http://openvswitch.org/mailman/listinfo/dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openvswitch.org/pipermail/ovs-dev/attachments/20140604/84b37c68/attachment-0005.html>
More information about the dev
mailing list