git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH 04/10] test-lib: Replace uses of $(expr ...) by POSIX shell features.

From
Johannes Schindelin <johannes.schindelin@gmx.de>
Date
Mar 19, 2009, 10:27 UTC
Message-ID
<alpine.DEB.1.00.0903191124590.10279@pacific.mpi-cbg.de>
In-Reply-To
<49C1F673.9050500@viscovery.net>
Hi,
On Thu, 19 Mar 2009, Johannes Sixt wrote:
Show 24 quoted lines
> Johannes Schindelin schrieb:
> 
> > On Wed, 18 Mar 2009, Johannes Sixt wrote:
> > 
> >> In particular:
> >>
> >> - Test case counting can be achieved by arithmetic expansion.
> >>
> >> - The name of the test, e.g. t1234, can be computed with ${0%%} and 
> >>   ${0##}.
> >>
> >> Signed-off-by: Johannes Sixt <j6t@kdbg.org>
> > 
> > I guess this makes the tests less slow on Windows?  Do you have 
> > numbers?
> 
> Actually, while reading through test-lib.sh I found those expr 
> expressions quite difficult to understand, and my primary intent was to 
> make the code more readable. Furthermore, as you can see in the hunk 
> that touches test_known_broken_{ok,failure}_ that the $(( )) construct 
> is already in use, so it's also a change to improve consistency.
> 
> The shorter runtime (primarily on Windows) is just a nice side effect, 
> although the gain probably vanishes in the noise.

Actually, I should not have written that mail that late at night: 'expr' is a bash builtin.

Show 7 quoted lines
> > FWIW I run the tests on Windows with -j10 these days, and they take 
> > about 15 minutes on a quad core 3GHz machine (which I may use from 
> > time to time; the machine is not mine, otherwise it would run Linux).
> 
> Last time I tried -j<something> it bailed out early. I didn't try again 
> since then. Sequential tests finish in 30-40 minutes here, but I don't 
> run SVN tests.

In msysGit, I updated the /share/msysGit/run-tests.sh script to make use of -j5. If you work on a newer branch than 'devel', you most probably need the changes from 'release-preview', as my test-results/<basename>-<pid> patch broke the original assumption of run-tests.sh.

Ciao, Dscho

Previous: Johannes SixtNext: Johannes Sixt
Message 12 of 27 in “Test on Windows - prequel”
  1. 00/11 Test on Windows - prequelJohannes Sixt, Mar 18, 2009
  2. 01/10 t9400, t9401: Do not force hard-linked cloneJohannes Sixt, Mar 18, 2009
  3. 02/10 test suite: Use 'say' to say something instead of 'test_expect_success'Johannes Sixt, Mar 18, 2009
  4. Johannes SchindelinMar 18, 2009
  5. Johannes SixtMar 19, 2009
  6. Johannes SchindelinMar 19, 2009
  7. Junio C HamanoMar 19, 2009
  8. 03/10 Call 'say' outside test_expect_successJohannes Sixt, Mar 18, 2009
  9. 04/10 test-lib: Replace uses of $(expr ...) by POSIX shell features.Johannes Sixt, Mar 18, 2009
  10. Johannes SchindelinMar 18, 2009
  11. Johannes SixtMar 19, 2009
  12. Johannes SchindelinMar 19, 2009
  13. 05/10 test-lib: Simplify test counting.Johannes Sixt, Mar 18, 2009
  14. Johannes SchindelinMar 18, 2009
  15. Johannes SixtMar 19, 2009
  16. 06/10 test-lib: Introduce test_chmod and use it instead of update-index --chmodJohannes Sixt, Mar 18, 2009
  17. 07/10 t7300: fix clean up on WindowsJohannes Sixt, Mar 18, 2009
  18. 08/10 t2200, t7004: Avoid glob pattern that also matches filesJohannes Sixt, Mar 18, 2009
  19. Junio C HamanoMar 19, 2009
  20. Johannes SixtMar 19, 2009
  21. Junio C HamanoMar 19, 2009
  22. 09/10 t5300, t5302, t5303: Do not use /dev/zeroJohannes Sixt, Mar 18, 2009
  23. 10/10 t5602: Work around path mangling on MSYSJohannes Sixt, Mar 18, 2009
  24. Junio C HamanoMar 18, 2009
  25. Johannes SixtMar 19, 2009
  26. Johannes SixtMar 19, 2009
  27. Junio C HamanoMar 19, 2009

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.