Some minor refactoring for iOS:
- Roll back clar changes; these should be a bit more measured, and occur
in clar upstream.
- Move iOS to nightly builds
Linux updated its ASLR randomization in a way that is incompatible with
TSAN. See https://github.com/google/sanitizers/issues/1716
Reducing the randomness for ASLR allows the sanitizers to cope.
Keep the push options tests more constrained to our CI environment;
writing files within the test sandbox instead of outside of it. Provide
the path to the output file in the test data. In addition, add the
repository to the test resources instead of recreating the hooks every
time.
Using modern rsa (sha2-256 or sha2-512) with libssh2 is complicated and
depends on numerous factors for support. Just use ecdsa, which is
supported by both libssh2 v1.11.0 and modern OpenSSH (which we use for
our server in CI).
Previously, users could skip certain tests when running the CI script
(`SKIP_ONLINE_TESTS=1`). Provide a mechanism for users to opt-in to
only certain tests (`SKIP_TESTS=1 SKIP_ONLINE_TESTS=0`).
GitHub Actions has borked their homebrew setup by first `brew
installing` things into `/usr/local` _and then_ putting their
own things in their place (eg `python`).
This breaks Homebrew, since it thinks it has `python` installed, but
it's actually something else.
Try to avoid using things that are in this bad state.
https://github.com/orgs/community/discussions/78266
Callers can specify the ssh command to invoke using `core.sshcommand` or
the `GIT_SSH` environment variable. This is useful for specifying
alternate configuration, and is particularly useful for our testing
environment.
Make socket I/O non-blocking and add optional timeouts.
Users may now set `GIT_OPT_SET_SERVER_CONNECT_TIMEOUT` to set a shorter
connection timeout. (The connect timeout cannot be longer than the
operating system default.) Users may also now configure the socket read
and write timeouts with `GIT_OPT_SET_SERVER_TIMEOUT`.
By default, connects still timeout based on the operating system
defaults (typically 75 seconds) and socket read and writes block.
Add a test against our custom testing git server that ensures that we
can timeout reads against a slow server.
We provide `BUILD_PATH` to our build script; provide it and mutate
`PATH` when running our tests as well.
We were previously using `cygpath` to try to convert a _list_ of Windows
paths into cygwin / Unix style `PATH` format. This does not work -- it
treats the path list as a single path (with semicolons -- understandably
as those are allowed characters in a Windows path).
For example, `C:\One;C:\Two;C:\Three` is converted to
`/c/one;c:/two;c:/three`.
Add a new function to convert path lists, so that paths are split by
semicolon and fed to `cygpath` independently, then re-joined with a
colon. This means that our example `C:\One;C:\Two;C:\Three` is correctly
converted to `/c/one:/c/two:/c/three`.
libgit2 can now isolate its home directory, and our test runner (by
default) isolates the home directory. In our CI environment, we want to
set up some pieces (like ssh configuration) in a fake homedir. Continue
to do so and propagate that to clar.
We found that the best way to test push options was to receive them via a git hooks script, and output them to a location that the CI tests could read to check and see if the push options were interpreted by git correctly.
Co-Authored-By: pireads <pireads@gmail.com>
Co-Authored-By: lotdeef <lcfisch2@asu.edu>
Co-Authored-By: PSI497 <497.psi.497@gmail.com>
Currently just the one test needs it.
The ssh-rsa makes sure we're asking for the cipher we find in `known_hosts` as
that won't be the one selected by default. This will be relevant in later changes.
Test that we can successfully clone a repository that is namespace
scoped on the remote and does not advertise a HEAD. To do this, we must
specify the branch to checkout.
Test that we can successfully clone a repository that is namespace
scoped to a bare repository locally. We need not specify a checkout
branch in this case (obviously, since we do not check anything out in a
bare clone).
We previously (correctly) cleaned up the git daemon and SSH server, but
failed to clean up our bespoke HTTP server and HTTP proxies. Capture
their PIDs on process creation and kill them when we shut down.