git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Bryan Donlan <bdonlan@fushizen.net>
To: git@vger.kernel.org
Cc: Johannes Sixt <j.sixt@viscovery.net>,
	Adam Roben <aroben@apple.com>,
	gitster@pobox.com, Bryan Donlan <bdonlan@fushizen.net>
Subject: [PATCH v3 00/10] Fix git's test suite to pass when the path contains spaces
Date: Sun,  4 May 2008 01:37:50 -0400	[thread overview]
Message-ID: <1209879480-16910-1-git-send-email-bdonlan@fushizen.net> (raw)
In-Reply-To: <1207810216-27871-1-git-send-email-bdonlan@fushizen.net>

This patch series fixes bugs in git and git's testsuite to allow all tests
to pass when the working directory contains whitespace and/or shell
metacharacters.

The first three patches in this series fix bugs in git itself that were
uncovered in the process of fixing the test suite. Each contains additional
tests and/or updates to existing tests to exercise the bug in question.

Patches 4 and 5 set up an abstraction for safe handling of editor variables
in tests when we have odd paths; and 6-7 fix bugs in the test libraries.
Patch 8 cleans up some instances of the unportable export FOO=bar construct
in the test suite; patch 9 fixes the remaining individual tests to be
space-sane, and finally 10 arranges for the test suite to always run with the
trash directory name containing spaces, to help prevent regressions in the
future.

Significant changes since v2:
  * Use only spaces in the trash dir names for Windows compatibility
  * Avoid ugliness like \"\$GIT_DIR\"

This series is also available by:
  git pull git://repo.or.cz/git/bdonlan.git wst-submit3

Sorry for the long delay in updating the series; I've been consumed with
schoolwork lately :)

Since it was mentioned providing conversion scripts was useful in review, here
is a hacky script I put together to help fixup the quotation:

http://fushizen.net/~bd/requote.pl

This script was applied on t/t*svn*.sh, then followed by a few manual fixes,
review, and git add -i to change only the chunks that I had made worse in the
previous patches. Note however that the conversion of "->' in places makes for
a large diff...

Bryan Donlan (10):
  git-rebase.sh: Fix --merge --abort failures when path contains
    whitespace
  config.c: Escape backslashes in section names properly
  git-send-email.perl: Handle shell metacharacters in $EDITOR properly
  test-lib.sh: Add a test_set_editor function to safely set $VISUAL
  Use test_set_editor in t9001-send-email.sh
  test-lib.sh: Fix some missing path quoting
  lib-git-svn.sh: Fix quoting issues with paths containing shell
    metacharacters
  Don't use the export NAME=value form in the test scripts.
  Fix tests breaking when checkout path contains shell metacharacters
  Rename the test trash directory to contain spaces.

 config.c                                      |    2 +-
 git-rebase.sh                                 |    2 +-
 git-send-email.perl                           |    2 +-
 t/.gitignore                                  |    2 +-
 t/lib-git-svn.sh                              |    3 +-
 t/lib-httpd.sh                                |    3 +-
 t/t0000-basic.sh                              |    4 +-
 t/t1020-subdirectory.sh                       |   22 ++--
 t/t1303-wacky-config.sh                       |    6 +
 t/t1500-rev-parse.sh                          |    9 +-
 t/t1501-worktree.sh                           |   34 +++---
 t/t3050-subprojects-fetch.sh                  |    2 +-
 t/t3400-rebase.sh                             |    3 +-
 t/t3404-rebase-interactive.sh                 |    3 +-
 t/t3407-rebase-abort.sh                       |   33 +++--
 t/t3500-cherry.sh                             |    3 +-
 t/t5500-fetch-pack.sh                         |    4 +-
 t/t5512-ls-remote.sh                          |    2 +-
 t/t5516-fetch-push.sh                         |    6 +-
 t/t5700-clone-reference.sh                    |    2 +-
 t/t5710-info-alternate.sh                     |    4 +-
 t/t6000lib.sh                                 |    9 +-
 t/t6010-merge-base.sh                         |    9 +-
 t/t6200-fmt-merge-msg.sh                      |    6 +-
 t/t7003-filter-branch.sh                      |    2 +-
 t/t7004-tag.sh                                |    3 +-
 t/t7010-setup.sh                              |    2 +-
 t/t7300-clean.sh                              |    2 +-
 t/t7501-commit.sh                             |    8 +-
 t/t7504-commit-msg-hook.sh                    |   23 ++--
 t/t7505-prepare-commit-msg-hook.sh            |   17 ++-
 t/t9001-send-email.sh                         |    5 +-
 t/t9100-git-svn-basic.sh                      |  120 +++++++++---------
 t/t9101-git-svn-props.sh                      |    8 +-
 t/t9102-git-svn-deep-rmdir.sh                 |   20 ++--
 t/t9103-git-svn-tracked-directory-removed.sh  |   20 ++--
 t/t9104-git-svn-follow-parent.sh              |  172 ++++++++++++------------
 t/t9105-git-svn-commit-diff.sh                |   32 +++---
 t/t9106-git-svn-commit-diff-clobber.sh        |   56 ++++----
 t/t9106-git-svn-dcommit-clobber-series.sh     |   30 ++--
 t/t9107-git-svn-migrate.sh                    |  124 +++++++++---------
 t/t9108-git-svn-glob.sh                       |   76 ++++++------
 t/t9110-git-svn-use-svm-props.sh              |   12 +-
 t/t9111-git-svn-use-svnsync-props.sh          |   12 +-
 t/t9112-git-svn-md5less-file.sh               |    4 +-
 t/t9113-git-svn-dcommit-new-file.sh           |   10 +-
 t/t9114-git-svn-dcommit-merge.sh              |   22 ++--
 t/t9115-git-svn-dcommit-funky-renames.sh      |   12 +-
 t/t9116-git-svn-log.sh                        |   12 +-
 t/t9117-git-svn-init-clone.sh                 |   30 ++--
 t/t9118-git-svn-funky-branch-names.sh         |   24 ++--
 t/t9120-git-svn-clone-with-percent-escapes.sh |    6 +-
 t/t9121-git-svn-fetch-renamed-dir.sh          |   12 +-
 t/t9500-gitweb-standalone-no-errors.sh        |   25 ++--
 t/test-lib.sh                                 |   22 +++-
 55 files changed, 575 insertions(+), 523 deletions(-)

  parent reply	other threads:[~2008-05-04  5:39 UTC|newest]

Thread overview: 60+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-04-09  1:29 [PATCH 0/8] Fix git's test suite to pass when the path contains spaces Bryan Donlan
2008-04-09  1:29 ` [PATCH 1/8] git-rebase.sh: Fix --merge --abort failures when path contains whitespace Bryan Donlan
2008-04-09  1:29   ` [PATCH 2/8] config.c: Escape backslashes in section names properly Bryan Donlan
2008-04-09  1:29     ` [PATCH 3/8] git-send-email.perl: Handle shell metacharacters in $EDITOR properly Bryan Donlan
2008-04-09  1:30       ` [PATCH 4/8] test-lib.sh: Fix some missing path quoting Bryan Donlan
2008-04-09  1:30         ` [PATCH 5/8] test-lib.sh: Add a test_set_editor function to safely set $VISUAL Bryan Donlan
2008-04-09  1:30           ` [PATCH 6/8] lib-git-svn.sh: Fix quoting issues with paths containing shell metacharacters Bryan Donlan
2008-04-09  1:30             ` [PATCH 7/8] Use test_set_editor in t9001-send-email.sh Bryan Donlan
2008-04-09  1:30               ` [PATCH 8/8] Fix tests breaking when checkout path contains shell metacharacters Bryan Donlan
     [not found]                 ` <47FC69B8.40809@viscovery.net>
     [not found]                   ` <20080410063028.GA12562@shion.is.fushizen.net>
2008-04-10  6:49                     ` Johannes Sixt
2008-04-10  7:02                       ` Bryan Donlan
2008-04-10  7:24                       ` Junio C Hamano
2008-04-09  7:01               ` [PATCH 7/8] Use test_set_editor in t9001-send-email.sh Johannes Sixt
2008-04-09 14:16                 ` Bryan Donlan
2008-04-09  6:50             ` [PATCH 6/8] lib-git-svn.sh: Fix quoting issues with paths containing shell metacharacters Junio C Hamano
2008-04-09  6:36           ` [PATCH 5/8] test-lib.sh: Add a test_set_editor function to safely set $VISUAL Johannes Sixt
2008-04-09  6:31       ` [PATCH 3/8] git-send-email.perl: Handle shell metacharacters in $EDITOR properly Johannes Sixt
2008-04-09 14:28         ` Bryan Donlan
2008-04-10  3:39         ` Junio C Hamano
2008-04-09  6:31     ` [PATCH 2/8] config.c: Escape backslashes in section names properly Johannes Sixt
2008-04-09 14:13       ` Bryan Donlan
2008-04-09 14:25         ` Johannes Sixt
2008-04-09  6:50   ` [PATCH 1/8] git-rebase.sh: Fix --merge --abort failures when path contains whitespace Junio C Hamano
2008-04-09  6:55   ` Johannes Sixt
2008-04-09 14:37     ` Bryan Donlan
2008-04-09 14:51       ` Johannes Sixt
2008-04-09 15:02         ` Bryan Donlan
2008-04-10  6:10           ` Johannes Sixt
2008-04-10  6:50 ` [PATCH v2 00/10] Fix git's test suite to pass when the path contains spaces Bryan Donlan
2008-04-10  6:50   ` [PATCH v2 01/10] git-rebase.sh: Fix --merge --abort failures when path contains whitespace Bryan Donlan
2008-04-10  6:50     ` [PATCH v2 02/10] config.c: Escape backslashes in section names properly Bryan Donlan
2008-04-10  6:50       ` [PATCH v2 03/10] git-send-email.perl: Handle shell metacharacters in $EDITOR properly Bryan Donlan
2008-04-10  6:50         ` [PATCH v2 04/10] test-lib.sh: Add a test_set_editor function to safely set $VISUAL Bryan Donlan
2008-04-10  6:50           ` [PATCH v2 05/10] Use test_set_editor in t9001-send-email.sh Bryan Donlan
2008-04-10  6:50             ` [PATCH v2 06/10] test-lib.sh: Fix some missing path quoting Bryan Donlan
2008-04-10  6:50               ` [PATCH v2 07/10] lib-git-svn.sh: Fix quoting issues with paths containing shell metacharacters Bryan Donlan
2008-04-10  6:50                 ` [PATCH v2 08/10] Don't use the export NAME=value form in the test scripts Bryan Donlan
2008-04-10  6:50                   ` [PATCH v2 09/10] Fix tests breaking when checkout path contains shell metacharacters Bryan Donlan
2008-04-10  6:50                     ` [PATCH v2 10/10] Rename the test trash directory to contain " Bryan Donlan
2008-04-10  7:45     ` [PATCH v2 01/10] git-rebase.sh: Fix --merge --abort failures when path contains whitespace Junio C Hamano
2008-04-10  8:48       ` Bryan Donlan
2008-04-11 22:37       ` Junio C Hamano
2008-05-04  5:37   ` Bryan Donlan [this message]
2008-05-04  5:37     ` [PATCH v3 " Bryan Donlan
2008-05-04  5:37       ` [PATCH v3 02/10] config.c: Escape backslashes in section names properly Bryan Donlan
2008-05-04  5:37         ` [PATCH v3 03/10] git-send-email.perl: Handle shell metacharacters in $EDITOR properly Bryan Donlan
2008-05-04  5:37           ` [PATCH v3 04/10] test-lib.sh: Add a test_set_editor function to safely set $VISUAL Bryan Donlan
2008-05-04  5:37             ` [PATCH v3 05/10] Use test_set_editor in t9001-send-email.sh Bryan Donlan
2008-05-04  5:37               ` [PATCH v3 06/10] test-lib.sh: Fix some missing path quoting Bryan Donlan
2008-05-04  5:37                 ` [PATCH v3 07/10] lib-git-svn.sh: Fix quoting issues with paths containing shell metacharacters Bryan Donlan
2008-05-04  5:37                   ` [PATCH v3 08/10] Don't use the export NAME=value form in the test scripts Bryan Donlan
2008-05-04  5:37                     ` [PATCH v3 09/10] Fix tests breaking when checkout path contains shell metacharacters Bryan Donlan
2008-05-04  5:38                       ` [PATCH v3 10/10] Rename the test trash directory to contain spaces Bryan Donlan
2008-05-05  8:25                         ` Johannes Sixt
2008-05-05  7:04                       ` [PATCH v3 09/10] Fix tests breaking when checkout path contains shell metacharacters Johannes Sixt
2008-05-05  7:57                         ` Bryan Donlan
2008-05-05  8:11                           ` Johannes Sixt
2008-05-05  7:03     ` [PATCH v3 00/10] Fix git's test suite to pass when the path contains spaces Johannes Sixt
2008-05-05  7:59       ` Bryan Donlan
2008-05-05  8:19         ` Johannes Sixt

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=1209879480-16910-1-git-send-email-bdonlan@fushizen.net \
    --to=bdonlan@fushizen.net \
    --cc=aroben@apple.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=j.sixt@viscovery.net \
    /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;
as well as URLs for NNTP newsgroup(s).