From: Junio C Hamano Date: Wed, 01 Jul 2026 22:27:04 GMT Subject: Re: [PATCH v2 1/4] t1517: skip svn tests if svn is not installed Message-ID: In-Reply-To: <20260701212442.1430084-2-sandals@crustytoothpaste.net> "brian m. carlson" writes: > +test_lazy_prereq SVN ' > + test_have_prereq PERL && test -n "$NO_SVN_TESTS" && perl -w -e " > + use SVN::Core; > + use SVN::Repos; > + \$SVN::Core::VERSION gt '1.1.0' or exit(42); > + " > +' If "have_prereq PERL" is not satisfied, SVN is not satisfied. If NO_SVN_TESTS is an empty string (or unset), "test -n" fails, and SVN is not satisfied. Questionable---am I misreading this part of the logic??? The perl script would not barf only if use SVN::* succeed and then SVN::Core::VERSION is strictly better than '1.1.0'. If not, i.e., libsvn-perl is not available, or its version is older, then we fail with exit(42), and SVN is not satisfied. > test_expect_success 'set up a non-repo directory and test file' ' > GIT_CEILING_DIRECTORIES=$(pwd) && > export GIT_CEILING_DIRECTORIES && > @@ -138,6 +146,8 @@ do > case "$cmd" in > instaweb) > prereq=PERL ;; > + svn) > + prereq=SVN ;; > *) > prereq= ;; > esac