Re: [PATCH v2 0/4] remote-helpers: trivial test fixes
- From
Felipe Contreras <felipe.contreras@gmail.com>
- Date
- Apr 6, 2013, 17:29 UTC
- Message-ID
- <CAMP44s0Lbg-_JKPR6WF6Qhkz7cgweHejA-T_V3mCO73a4iXpNA@mail.gmail.com>
- In-Reply-To
- <51605546.3080503@web.de>
On Sat, Apr 6, 2013 at 11:03 AM, Torsten Bögershausen <tboegi@web.de> wrote:
Show 34 quoted lines
> On 04.04.13 17:36, Felipe Contreras wrote: >> Hi, >> >> A reroll, now we do some checks, just avoid test-lint-duplicates, and fix the >> outsanding shell portability issue. The rest is the same. >> >> Felipe Contreras (4): >> remote-bzr: avoid echo -n >> remote-helpers: fix the run of all tests >> remote-bzr: remove stale check code for tests >> remote-hg: fix hg-git test-case >> >> contrib/remote-helpers/Makefile | 1 + >> contrib/remote-helpers/test-bzr.sh | 16 +--------------- >> contrib/remote-helpers/test-hg-hg-git.sh | 1 - >> 3 files changed, 2 insertions(+), 16 deletions(-) >> > Sorry being late, now I installed bzr and hg on one of my machines > > One defect found: "\s" is not portable on all grep versions > A "*" is not a "basic regular expression", so we need to use egrep > > > diff --git a/contrib/remote-helpers/test-hg.sh b/contrib/remote-helpers/test-hg.sh > index 5f81dfa..2e80c11 100755 > --- a/contrib/remote-helpers/test-hg.sh > +++ b/contrib/remote-helpers/test-hg.sh > @@ -115,7 +115,7 @@ test_expect_success 'update bookmark' ' > git push > ) && > > - hg -R hgrepo bookmarks | grep "devel\s\+3:" > + hg -R hgrepo bookmarks | egrep "devel[[:space:]]+3:" > '
I would rather use [ \t] instead.
Show 12 quoted lines
> 2 mninor nits: > > diff --git a/contrib/remote-helpers/test-bzr.sh b/contrib/remote-helpers/test-bzr.sh > index 8450432..7970f9e 100755 > --- a/contrib/remote-helpers/test-bzr.sh > +++ b/contrib/remote-helpers/test-bzr.sh > @@ -13,7 +13,7 @@ if ! test_have_prereq PYTHON; then > fi > > if ! "$PYTHON_PATH" -c 'import bzrlib'; then > - skip_all='skipping remote-bzr tests; bzr not available' > + skip_all='skipping remote-bzr tests; python bzrlib not available'
"python bzrlib" is meaningless to the user; bazaar provides it; basically all the code is there.
Show 13 quoted lines
> test_done > fi > > diff --git a/contrib/remote-helpers/test-hg-hg-git.sh b/contrib/remote-helpers/test-hg-hg-git.sh > index 3f253b7..5d87282 100755 > --- a/contrib/remote-helpers/test-hg-hg-git.sh > +++ b/contrib/remote-helpers/test-hg-hg-git.sh > @@ -21,7 +21,7 @@ if ! "$PYTHON_PATH" -c 'import mercurial'; then > fi > > if ! "$PYTHON_PATH" -c 'import hggit'; then > - skip_all='skipping remote-hg tests; hg-git not available' > + skip_all='skipping remote-hg tests; python hggit not available'
Same. Google for 'python hggit' and the result is hg-git; and that's what you would actually tell your package manager to install.
Cheers.
-- Felipe Contreras