The vendor Ruby will be put inside `Library/Homebrew/vendor/portable-ruby/<version>`,
with a symlink `Library/Homebrew/vendor/portable-ruby/current` pointed to it.
In addition, a `Library/Homebrew/vendor/portable-ruby-version` will
track the latest version of vendor binaries.
This gives us version control on vendor Ruby and enables us to bump vendor
Ruby whenever needed such as security update.
Fix minor regression in b55250c44eacd49646407b26a73753965d4d36d0. The
bottle is placed in the current working directory, is unaffected by the
the single teardown introduced in #475, and thus needs manual handling.
Closes#483.
Signed-off-by: Martin Afanasjew <martin@afanasjew.de>
Test was added in 61614d35294c8faffaeb5c7f0ec6dea78dbbc30f, but never
had any effect because it was replaced by a method of the same name a
few lines further down.
We might as well be consistent about it, since it's not obvious to people
what the next step is after we've pointed out the directory isn't writable.
Fixes#476.
* readall: move readall logic to new class.
* tap: run readall when tapping.
This will prevent tapping an tap with syntax errors from causing issues
for users.
Fixes#58.
Instead of writing a custom ensure for every test let's just nuke
all the files every time. This may be something we might want to use for
other unit tests too. It leans heavily on the fact that a
`FileUtils.rm_rf` on files that don't exist is very quick and things
like `brew cleanup` are super slow in comparison.
Before:
```
$ brew tests --only=integration_cmds --official-cmd-taps
Finished in 49.764724s, 1.0047 runs/s, 5.2648 assertions/s.
```
After:
```
$ brew tests --only=integration_cmds --official-cmd-taps
Finished in 43.014769s, 1.1624 runs/s, 5.8352 assertions/s.
```
The `build` and `source_modified_time` arguments are always coming from
the matching attributes of the `Formula` instance. Thus query `formula`
for them instead of passing them individually.
* Don't infinitely recurse `brew update --preinstall`.
This could happen when trying to `brew install git` inside `brew update
--preinstall`.
* update.sh: cache Git PATH.
We don’t need to look it up from superenv every time; this is slow.
* update.sh: print message before preinstall updates.
* update.sh: verbose output fetch directory.
This aids reading `brew update --verbose --debug` output.
* update.sh: skip taps without formulae on preinstall.
We don’t need to update them as we’re not invoking them.
* update.sh: don't force update-report on developer preinstall.
This is too slow.
The length of the commit hash returned for `--short` can vary depending
on user configuration. Make sure this works independently of what might
have been configured via a user's `.gitconfig`. This also fixes the
failing `GitDownloadStrategyTests#test_last_commit` test for such users.
Add an extension for accessing Git-related meta data that can be mixed
in into a Pathname object (e.g. `HOMBREW_REPOSITORY` or the path of a
`Tap` instance). The goal here is to eliminate code duplication.
Implement:
* VCSDownloadStrategy#last_commit
Use last modified file timestamp
* SubversionDownloadStrategy#last_commit
Use `svn info --show-item revision`
* GitDownloadStrategy#last_commit
Use `git rev-parse HEAD`
* MercurialDownloadStrategy#last_commit
Use `hg parent --template {node}`
* BazaarDownloadStrategy#last_commit
Use `bazaar revno`
* FossilDownloadStrategy#last_commit
Use `fossil info tip`
Beta versions of XQuartz have address sanitization enabled, which
breaks some software at runtime, including wine.
Closes Homebrew/homebrew-core#2481.
Closes#459.
Signed-off-by: Misty De Meo <mistydemeo@github.com>
Rearrange path constants such that persistent paths (that point into the
Homebrew code base) are in one spot and all other paths (that are being
redirected to a temporary location for the duration of the test run) are
grouped together.
Closes#440.
Signed-off-by: Martin Afanasjew <martin@afanasjew.de>
Prior to the fix, every run of the test suite would leave behind a pair
of empty directories in `$TMPDIR`. (A temporary home directory was
created but only its child `Applications` was wiped when done.)