Avoid failures in svnserve tests when run in parallel

Setting SVNSERVE_PORT enables several tests which require a local
svnserve daemon to be run (in t9113 & t9126).  The tests share setup of
the local svnserve via `start_svnserve()`.  The function uses svnserve's
`--listen-once` option, which causes svnserve to accept one connection
on the port, serve it, and exit.  When running the tests in parallel
this fails if one test tries to start svnserve while the other is still
running.

Use the test number as the svnserve port (similar to httpd tests) to
avoid port conflicts.  Set GIT_TEST_SVNSERVE to enable these tests.

The change should make it into 2.16 or 2.17.  Until then, setting
GIT_TEST_SVNSERVE will disable the svnserve tests.  There are only a few
tests affected and this allows more testing with parallel test runs, so
it's a reasonable trade.  Once an upstream release with these changes
arrives, we'll begin running these tests without any further changes.
This commit is contained in:
Todd Zullinger 2017-11-30 17:46:45 -05:00
parent 15d075cb09
commit db2eb1dae4

View File

@ -639,8 +639,8 @@ export GIT_SKIP_TESTS
# Set LANG so various UTF-8 tests are run
export LANG=en_US.UTF-8
# Set SVNSERVE_PORT to run svnserve tests
export SVNSERVE_PORT=9000
# Run git svn tests which use svnserve
export GIT_TEST_SVNSERVE=true
# Run the tests
GIT_TEST_OPTS='--verbose-log' make %{?make_test_opts} test || \
@ -804,6 +804,7 @@ rm -rf %{buildroot}
- Remove second make invocation for doc build/install
- Fix builds using '--without docs'
- Mark git-core-docs sub-package noarch
- Avoid failures in svnserve tests when run in parallel
* Wed Nov 29 2017 Todd Zullinger <tmz@pobox.com> - 2.15.1-2
- Fix debuginfo for gnome-keyring and libsecret credential helpers