On Mon, Aug 2, 2010 at 10:03, Matthieu Moy <Matthieu.Moy@xxxxxxx> wrote: > +use usual shell commands like "cd". The commands are ran from the same "are run from the same" > +directory as "rebase -i" was started (this directory is temporarily > +re-created if needed). "was started in" > +file_must_exist () { > + if ! [ -f "$1" ]; then > + echo "file $1 not created." > + false > + fi > +} > + > +file_must_not_exist () { > + if [ -f "$1" ]; then > + echo "file $1 created while it shouldn't have. $2" > + false > + fi > +} > + > +dir_must_exist () { > + if ! [ -d "$1" ]; then > + echo "dir $1 does not exist." > + false > + fi > +} > + > +dir_must_not_exist () { > + if [ -d "$1" ]; then > + echo "dir $1 exists while it shouldn't. $2" > + false > + fi > +} Leftover debugging code? Looks useful, but probably something we should have in test-lib.sh as "git_test" as a wrapper for the "test" built-in. -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html