19 Commits

Author SHA1 Message Date
Markus Reiter
d508b124a4 Rename/merge test files. 2016-09-27 00:15:56 +02:00
Mike McQuaid
3982950e61 rubocop --auto-correct all hash-rocket usage. 2016-09-17 16:14:13 +01:00
Andrea Kao
8ec59253df tests: fix code style issues (#587) 2016-08-06 07:04:59 +02:00
Martin Afanasjew
54d1e99ffe tap: test fetch/validation of invalid tap names 2016-07-27 21:25:13 +02:00
Mike McQuaid
4da990587f tap: run readall when tapping. (#396)
* 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.
2016-07-09 13:51:19 +01:00
Xu Cheng
71b6e0aa18 Tap#install: better TapRemoteMismatchError check
* remote check requires `git` installed.
* Do not perform check if user does not passing remote explicitly.

Fixes #108
2016-04-19 16:29:29 +08:00
Xu Cheng
548be81b34 tap: various improvements (#77)
* make `read_or_set_private_config` private
* add doc
* add test
2016-04-12 18:51:43 +08:00
ilovezfs
fad235d8e8 tap: support --full even if installed
Makes `tap` re-runnable and unshallows when requested with `--full`.
Tapping with a different URL raises an exception.

The homebrew/core tap cannot be untapped with `untap` so running
`brew tap --full homebrew/core` is now a built-in way to get a full
clone of this tap without resorting to workarounds.

Closes #17.

Signed-off-by: ilovezfs <ilovezfs@icloud.com>
2016-04-05 07:25:27 -07:00
Xu Cheng
deea4c82a4 fix brew tests
Fix the `brew tests` problem caused by core/formula separation.
2016-04-02 21:51:36 +08:00
Mike McQuaid
041c8502c5 Set HOMEBREW_API_TOKEN from Git when available.
As requested in Homebrew/homebrew#46578. Falls back to existing functionality.

Closes Homebrew/homebrew#46578.

Closes Homebrew/homebrew#49846.

Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
2016-03-08 20:52:11 +08:00
Xu Cheng
28f3dae8cd rename CoreFormulaRepository to CoreTap
Core tap will be separated from core code in the near future.
It makes sense to rename it to CoreTap.
2016-03-07 19:43:46 +08:00
Xu Cheng
9f96e41b40 tap: add methods to get git related information
These methods will be used in `brew --version`, `brew config`
and `brew doctor` after core/formula separation.

Closes Homebrew/homebrew#49796.

Signed-off-by: Xu Cheng <xucheng@me.com>
2016-03-06 13:51:06 +08:00
Xu Cheng
87ecd621eb add Tap#tap_migrations
This enables tap migration feature in per tap case, which will
ultimately help core/formula separation.
2016-02-25 17:22:28 +08:00
Xu Cheng
4e51c0b8ea add Tap#formula_file?
Return true if given path would present a Formula file in this Tap.
Accepts both absolute path and relative path (relative to this Tap's path)

It offer an abstraction such that caller would not need to worry about
low level file system in the tap.

It will be used in `brew pull` and `brew update`.

Closes Homebrew/homebrew#49191.

Signed-off-by: Xu Cheng <xucheng@me.com>
2016-02-16 14:23:39 +08:00
Xu Cheng
9810c2a412 test_tap: restore private remote test
Only test it if HOMEBREW_GITHUB_API_TOKEN is set.
2016-01-11 22:07:15 +08:00
Xu Cheng
86cc780ea2 test_tap: remove problematic test
`Tap#private?` requires Github API, which can cause problem on Travis CI
due to API rate limit.
2016-01-11 19:47:35 +08:00
Martin Afanasjew
c5f0003061 test: don't fail if GitHub API is unavailable
Tests shouldn't fail in case of an unavailable network or a deliberately
disabled access to the GitHub API.

Closes Homebrew/homebrew#47670.

Signed-off-by: Martin Afanasjew <martin@afanasjew.de>
2016-01-04 16:26:36 +01:00
Baptiste Fontaine
c15c9dbaf3 Tap#issues_url added
Closes Homebrew/homebrew#47454.

Signed-off-by: Baptiste Fontaine <batifon@yahoo.fr>
2015-12-30 00:44:46 +01:00
Xu Cheng
6bb341dc24 add test_tap 2015-12-19 22:05:30 +08:00