Patchwork [2,of,3,V4] test-run-tests.t: added test for '--time' option

login
register
mail settings
Submitter Anurag Goel
Date June 21, 2014, 4:21 p.m.
Message ID <ce69b3b23dbebf1b674f.1403367706@ubuntu.ubuntu-domain>
Download mbox | patch
Permalink /patch/5033/
State Changes Requested
Headers show

Comments

Anurag Goel - June 21, 2014, 4:21 p.m.
# HG changeset patch
# User anuraggoel <anurag.dsps@gmail.com>
# Date 1403365495 -19800
#      Sat Jun 21 21:14:55 2014 +0530
# Node ID ce69b3b23dbebf1b674f235036e97c78686aac63
# Parent  d7a0a8654dbb60ec0121975f82bb8d06369d8216
test-run-tests.t: added test for '--time' option

Below patch checks the behviour of '--time' option.
Pierre-Yves David - June 23, 2014, 8:47 a.m.
On 06/21/2014 09:21 AM, Anurag Goel wrote:
> # HG changeset patch
> # User anuraggoel <anurag.dsps@gmail.com>
> # Date 1403365495 -19800
> #      Sat Jun 21 21:14:55 2014 +0530
> # Node ID ce69b3b23dbebf1b674f235036e97c78686aac63
> # Parent  d7a0a8654dbb60ec0121975f82bb8d06369d8216
> test-run-tests.t: added test for '--time' option
>
> Below patch checks the behviour of '--time' option.
>
> diff -r d7a0a8654dbb -r ce69b3b23dbe tests/test-run-tests.t
> --- a/tests/test-run-tests.t	Sat Jun 21 21:06:56 2014 +0530
> +++ b/tests/test-run-tests.t	Sat Jun 21 21:14:55 2014 +0530
> @@ -19,6 +19,16 @@
>     .
>     # Ran 1 tests, 0 skipped, 0 warned, 0 failed.
>
> +test for --time
> +==================
> +
> +  $ $TESTDIR/run-tests.py --with-hg=`which hg` --time
> +  .
> +  # Ran 1 tests, 0 skipped, 0 warned, 0 failed.
> +  # Producing time report
> +  cuser   csys    real      Test
> +  [\d.\s]{23} test-success.t (re)

You expect 3 differents float values. write a more precise reg-exp

> +
>   failing test
>   ==================
>
> _______________________________________________
> Mercurial-devel mailing list
> Mercurial-devel@selenic.com
> http://selenic.com/mailman/listinfo/mercurial-devel
>

Patch

diff -r d7a0a8654dbb -r ce69b3b23dbe tests/test-run-tests.t
--- a/tests/test-run-tests.t	Sat Jun 21 21:06:56 2014 +0530
+++ b/tests/test-run-tests.t	Sat Jun 21 21:14:55 2014 +0530
@@ -19,6 +19,16 @@ 
   .
   # Ran 1 tests, 0 skipped, 0 warned, 0 failed.
 
+test for --time
+==================
+
+  $ $TESTDIR/run-tests.py --with-hg=`which hg` --time
+  .
+  # Ran 1 tests, 0 skipped, 0 warned, 0 failed.
+  # Producing time report
+  cuser   csys    real      Test
+  [\d.\s]{23} test-success.t (re)
+
 failing test
 ==================