Checkout Tools
  • last updated 4 hours ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
Teach our cmdline tests to optionally use a different kind of

repository layout than the classic greek tree.

The greek tree is not really suitable for testing peg revision parsing in

the client, since it has no files or directories with an @-sign in the

names. The new repository layout (called the trojan tree, heh heh) can be

selected at sandbox build time by each test case individually.

Note that we do not keep precooked versions of the trojan tree for FSFS

version compatibility tests, since its primary purpose is testing client

operations in the working copy.

[In subversion/tests/cmdline]

* davautocheck.sh: Add a <Location> to access the pristine trojan tree.

* pegrev_parse_tests.py

(do_move_with_at_signs): Use the trojan tree for the tests.

* svntest/actions.py

(_setup_pristine_repo): New; extracted from setup_pristine_greek_repository.

(setup_pristine_repositories): Renamed fom setup_pristine_greek_repository.

Build both the greek and the trojan pristine repositories. Update callers.

(_guarantee_repos): New; extracted from guarantee_greek_repository.

(guarantee_greek_repository): Just call _guarantee_repos.

(guarantee_trojan_repository): New.

(make_repo_and_wc): Add 'tree' parameter to select the greek or trojan tree.

* svntest/main.py:

(Item): Imported StateItem from svntest.wc.

(_item): Remove previsous alias for StateItem.

(pristine_trojan_repos_url,

pristine_trojan_repos_dir, trojan_dump_dir): New global variables.

(greek_state): Use Item instead of _item in initializer.

(trojan_state): New.

(execute_tests): Calculate the pristine_trojan_repos_url.

* svntest/sandbox.py

(Sandbox._set_name): Add 'tree' parameter to select the greek or trojan tree.

(Sandbox.build): Likewise, making 'greek' the default.

  1. … 4 more files in changeset.
* subversion/tests/cmdline/svnserveautocheck.sh: Document environment

variables interpreted by the script.

* subversion/tests/cmdline/davautocheck.sh: tweak documentation to be

in a similar form to svnserveautocheck.sh

  1. … 1 more file in changeset.
Add FSFS block-read support to davautocheck and svnserveautcheck. Now

make davautocheck BLOCK_READ=1

make svnserveautocheck BLOCK_READ=1

will enable block-read in svnserve and apache. Block-read is necessary

to trigger the issue 4725 bug.

* subversion/tests/cmdline/davautocheck.sh: Move common part of Location

block to a separate function, add support for BLOCK_READ env variable.

* subversion/tests/cmdline/svnserveautocheck.sh: Add support for

BLOCK_READ environment variable.

  1. … 1 more file in changeset.
Return a better error message when connecting to an URL on a server

that does not implement the DAV protocol.

* subversion/libsvn_ra_serf/options.c

(options_context_t): New member received_dav_header.

(capabilities_headers_iterator_callback):

Set it if the HTTP response contains the DAV: header.

(options_response_handler):

Bail out early with a specific message if the server doesn't support DAV.

* subversion/tests/cmdline/dav_tests.py: New test fixture.

* subversion/tests/cmdline/svntest/main.py

(other_dav_root_dir, non_dav_root_dir): New global variable.

(execute_tests): Initialize other_dav_root_dir and non_dav_root_dir.

* subversion/tests/cmdline/svntest/actions.py

(setup_pristine_greek_repository):

Create the directories for other_dav_root_dir and non_dav_root_dir.

* subversion/tests/cmdline/davautocheck.sh:

Load mod_dav_fs and configure httpd for dav_tests.py.

  1. … 4 more files in changeset.
* subversion/tests/cmdline/davautocheck.sh:

Support a --lldb option alongside --gdb.

* subversion/tests/cmdline/davautocheck.sh:

Silence an orphan output line ("Syntax OK" without "davautocheck.sh:" prefix).

Followup to r1809558, which was a follow-up to r1808955:

Silence a warning under httpd2.4 on Debian when bin/apache2 is installed but

the system-wide httpd.conf is not (the 'apache2-bin' package is installed and

the 'apache2' package isn't):

% ./davautocheck.sh

apache2: Could not open configuration file /etc/apache2/apache2.conf: No such file or directory

* subversion/tests/cmdline/davautocheck.sh:

Pass the config file to the version check. (!?)

Follow up to r1808955: 'apxs -q HTTPD_VERSION' does not work with 2.2.x.

* subversion/tests/cmdline/davautocheck.sh

(HTTPD_VERSION): Parse the version from 'httpd -V' and print it

when the server is started.

* subversion/tests/cmdline/davautocheck.sh:

Document the reason for using the run-time instead of compile-time HTTPD

version in the test driver.

The compile-time and run-time version of httpd may not be the same.

Since the tests rely on it to interpret test case results, make sure

that they see the run-time version.

* subversion/tests/cmdline/davautocheck.sh

(HTTPD_VERSION): New; get it from apxs.

Override the httpd version for 'make check' etc.

* subversion/tests/cmdline/davautocheck.sh:

Forbid APACHE_MPM=event with FS_TYPE=bdb.

* build/ac-macros/apache.m4

(SVN_FIND_APACHE): Reorder search to prefer local installations

over system installations.

* subversion/tests/cmdline/davautocheck.sh: Add comment.

  1. … 1 more file in changeset.
* subversion/tests/cmdline/davautocheck.sh: Remove duplicate <Location> block.

* subversion/tests/cmdline/davautocheck.sh: Fix typo.

Fix CVE-2015-3184: Have mod_authz_svn use ap_hook_force_authn where available.

* subversion/mod_authz_svn/mod_authz_svn.c

(access_checker): Support ap_force_authn_hook.

(force_authn): New.

(register_hooks): Register force_authn.

* build/ac-macros/apache.m4: Add --enable-broken-httpd-auth.

* subversion/tests/cmdline/mod_authz_svn_tests.py: New.

* subversion/tests/cmdline/svntest/main.py

(is_httpd_authz_provider_enabled): New.

* subversion/tests/cmdline/davautocheck.sh,

subversion/tests/cmdline/README,

win_tests.py: Add configuration for new tests.

  1. … 6 more files in changeset.
Support modern network utilities for finding free ports for tests

* subversion/tests/cmdline/davautocheck.sh:

Check for presence of ss, netstat and fail if neither is found.

Prefer ss to find a free port, fall back to netstat.

* subversion/tests/cmdline/svnserveautocheck.sh:

Same, and augment $PATH to include /usr/{,local/}sbin.

Patch by: Andreas Stieger <andreas.stieger{_AT_}gmx.de>

  1. … 1 more file in changeset.
Follow-up to r1421594: Fix (svnserve|dav)autocheck when time is only a

built-in.

Some shells do not treat variable contents as a keyword, which in the

case of time makes the script fail if it is a built-in but not a

command.

* subversion/tests/cmdline/svnserveautocheck.sh,

subversion/tests/cmdline/davautocheck.sh:

Turn TIME_CMD into a function.

Approved by: breser, danielsh

  1. … 1 more file in changeset.
Following up on r1659509, extend the whitespace cleanup script to include

.sql and .sh files

* tools/dev/remove-trailing-whitespace.sh

Update script.

* autogen.sh

* subversion/libsvn_wc/wc-metadata.sql

* subversion/libsvn_wc/wc-queries.sql

* subversion/tests/cmdline/dav-mirror-autocheck.sh

* subversion/tests/cmdline/davautocheck.sh

* subversion/tests/cmdline/lock_tests.py

* tools/buildbot/slaves/i686-debian-sarge1/svnlog.sh

* tools/buildbot/slaves/svn-x64-centos/svnbuild.sh

* tools/buildbot/slaves/svn-x64-centos/svnlog.sh

* tools/buildbot/slaves/svn-x64-macosx-gnu-shared/svnlog.sh

* tools/buildbot/slaves/svn-x64-macosx-gnu-shared-daily-ra_serf/svnlog.sh

* tools/buildbot/slaves/ubuntu-x64/svnlog.sh

* tools/client-side/svn-ssl-fingerprints.sh

* tools/dev/benchmarks/large_dirs/create_bigdir.sh

* tools/dist/dist.sh

* tools/dist/nightly.sh

* tools/hook-scripts/mailer/tests/mailer-init.sh

* tools/po/po-update.sh

Apply whitespace cleanup.

  1. … 18 more files in changeset.
Reintegrate the 'dump-load-cross-check' branch: implement optional dump/load

cross-checking in the test suite.

This is activated by passing 'DUMP_LOAD_CROSS_CHECK=1' to 'make check' and

friends, or by passing '--dump-load-cross-check' to the Python tests.

Remaining items mentioned in the BRANCH-README file were:

TODO:

- Fix FAIL: svnmucc_tests.py 2: a no-op content-change is reported

differently in different cases. (Fix it how? I'd prefer to make the

output of a no-op change the same as a no-change.)

Ideas for improvement:

- Improve the logic for finding repositories created by a test: detect

when a test created a repository even if the sandbox is not marked as

'built'; detect when a test created additional repositories.

- Implement the same cross-checking for the C tests.

  1. … 13 more files in changeset.
Extract the httpd version at configure time rather than in

davautocheck.sh, pass --httpd-version as a testsuite option

rather than using the environment SVNTEST_HTTPD_VERSION.

This is how other test flags support both 'make check' and

'make davautocheck'.

* subversion/tests/cmdline/davautocheck.sh

(SVNTEST_HTTPD_VERSION): Move code to apache.m4.

* build/ac-macros/apache.m4

(HTTPD_VERSION): Set value, based on code from davautocheck.sh.

* Makefile.in

(check): Pass --httpd-version.

* build/run_tests.py

(TestHarness.__init__, TestHarness._run_py_test, main): Add httpd_version.

* subversion/tests/cmdline/svntest/main.py

(is_mod_dav_url_quoting_broken): Use option rather than environment.

(TestSpawningThread.run_one): Handle --httpd-version.

(_create_parser): Add --httpd-version.

  1. … 4 more files in changeset.
Mark basic_tests.py 38 as XFAIL if running DAV tests with a version of

HTTPd where mod_dav has an URL quoting bug.

See: https://issues.apache.org/bugzilla/show_bug.cgi?id=56480

* subversion/tests/cmdline/davautocheck.sh:

Parse and export the HTTPd versions.

* subversion/tests/cmdline/svntest/main.py

(__mod_dav_url_quoting_broken_versions): New; the list of HTTPd versions

where mod_dav is known to have the bug described in PR 56480

(is_mod_dav_url_quoting_broken): New predicate.

* subversion/tests/cmdline/basic_tests.py

(special_paths_in_repos): Tag as XFail with the new predicate.

  1. … 2 more files in changeset.
* subversion/tests/cmdline/davautocheck.sh: Remove references to

--enable-dso which is no longer supported.

For things like 'gmake davautocheck' use the specified make program

for the nested make.

* Makefile.in

(davautocheck, svnserveautocheck): Set MAKE environment variable.

* subversion/tests/cmdline/davautocheck.sh: Use MAKE environment

variable if set.

* subversion/tests/cmdline/svnserveautocheck.sh: Use MAKE environment

variable if set.

  1. … 2 more files in changeset.
* subversion/tests/cmdline/davautocheck.sh: Don't use -q with diff as it

does not work on Solaris and is not needed in this instance.

* subversion/tests/cmdline/davautocheck.sh: Remove superfluous use of

ldd - on many platorms it was invoked on the libtool script rather

than the binary and so achieved nothing.

Tweak 'make davautocheck' and 'make svnserveautocheck' to work on

Solaris.

* Makefile.in:

(davautocheck, svnserveautocheck): Use the configured shell rather

than invoking the scripts directly.

* subversion/tests/cmdline/davautocheck.sh: Avoid "grep -q" as it is

not portable.

  1. … 1 more file in changeset.
* subversion/tests/cmdline/davautocheck.sh: Move DontDoThatConfigFile

to a directory that always exists.

* subversion/tests/cmdline/davautocheck.sh: Load mod_dontdothat,

create DontDoThatConfigFile, add ddt-test-work Location.

davautocheck: Prefork also needs the Mutex argument in 2.3.x+.

* subversion/tests/cmdline/davautocheck.sh: Use the Mutex directive for prefork

Fix davautocheck with httpd 2.3.x+ and worker MPM.

* subversion/tests/cmdline/davautocheck.sh: Make and setup a lock dir.