10460 Commits

Author SHA1 Message Date
Markus Reiter
c7267b123d Merge pull request #1502 from reitermarkus/load-metadata-cask-file
Load cask file in `.metadata` directory directly.
2016-11-21 10:43:15 +01:00
Markus Reiter
cc7541cbc4 Merge pull request #1535 from umireon/cask-pkg-choice
Cask: Add the choices option to pkg stanza
2016-11-21 10:25:30 +01:00
Mike McQuaid
b9d0d7719a cc: don't filter -fopenmp for non-llvm_clang.
We can filter it just for Clang and let it be used by anything else.
2016-11-21 08:50:01 +00:00
Mike McQuaid
28a00e9d6c development_tools: return llvm_clang Version class.
This was implemented before the rest of the file was refactored.
2016-11-21 08:49:29 +00:00
Mike McQuaid
a3f03e2066 development_tools: use begin/end
A more widely used style than relying on `if`/`else` returns.
2016-11-21 08:49:04 +00:00
Mike McQuaid
c1688be780 version/null: add inspect method.
This makes it easier to identify null versions when inspecting them.
2016-11-21 08:48:26 +00:00
Mike McQuaid
1710973792 Merge pull request #1540 from woodruffw/audit-check-blacklist
audit: check formula name against blacklisted names.
2016-11-21 07:52:05 +00:00
Kaito Udagawa
df635c8259 cask: compact the code 2016-11-21 04:13:29 +09:00
Mike McQuaid
947b850035 Merge pull request #1130 from aw1621107/allow-brew-llvm-for-openmp
Prefer brewed Clang over gcc-6 for needs :openmp
2016-11-20 12:38:28 +00:00
Mike McQuaid
a16bfa57e8 Merge pull request #1537 from umireon/nonfatal-requirement-message-once
install: suppress redundunt warnings with `depends_on` requirement
2016-11-20 11:59:57 +00:00
Kaito Udagawa
bcc9002214 install: print nothing if @requirement_messages is a String or nil 2016-11-20 19:49:58 +09:00
William Woodruff
4a9601ab82
audit: check formula name against blacklisted names. 2016-11-20 00:40:54 -05:00
Kaito Udagawa
0c22cc45e6 cask: Call Tempfile#close(true) with the choices file to ensure it deleted 2016-11-20 14:23:55 +09:00
Kaito Udagawa
2807202103 cask: use Tempfile and some style fixes 2016-11-19 14:52:38 +09:00
Markus Reiter
1834457272 Remove kernel extensions specified in uninstall :kext. 2016-11-19 01:53:26 +01:00
Markus Reiter
bd9755fd78 Load cask file in .metadata directory directly. 2016-11-18 23:02:58 +01:00
Kaito Udagawa
f4a3bc100b cask: add the choices option to pkg stanza
installer command accepts -applyChoiceChangesXML option to change
customize options on the GUI installer from the commandline.
(`man installer` for more detailed information)

The introduced option `choice` enables the choice changes to be supplied
via pkg stanza without tricks in preflight code.
2016-11-19 04:41:21 +09:00
Kaito Udagawa
61c8fff0ee install: suppress redundunt warnings with depends_on requirement
When a formula depends on any requirements, they evaluated at most three times:
before locking, before installing dependent, before building formula.
When a non-fatal requirement is specified and thus evaluated three times,
mostly the same warning message is also emitted three times.

This change restricts printing the warning messages only when a bottle is
successfully installed or before building.
Since this timing is after the final dependency computation for each cases,
the warnings will be most useful to check what is not yet satisfied.
2016-11-19 04:14:26 +09:00
Mike McQuaid
7853406fb4 Merge pull request #1515 from alyssais/formula_cache
Fix flaky tests.
2016-11-18 15:37:49 +00:00
Mike McQuaid
e8d5040141 testbottest: don't use TEST_FIXTURE_DIR.
This isn't defined for formulae.
2016-11-18 14:08:40 +00:00
Alex Wang
3e4544025d Prefer brewed Clang over gcc-6 for needs :openmp
Clang has fully implemented OpenMP support as of LLVM 3.7, so if OpenMP
is required by a formula gcc is no longer the only choice of compiler.

Clang should be preferred over gcc because using gcc meant linking
against libstdc++, which is ABI incompatible with libc++. This may be
unnoticeable for some users, but it causes other builds to fail, e.g.
pstoedit when imagemagick was built with OpenMP. pstoedit is required
for the octave formula, so for some users this could be a significant
problem.
2016-11-18 08:54:09 -05:00
Mike McQuaid
5e073f1f40 Merge pull request #1528 from MikeMcQuaid/audit-devel-revision
audit: don't check devel version_scheme/revision.
2016-11-18 13:53:22 +00:00
Mike McQuaid
0e2218807a Merge pull request #1529 from MikeMcQuaid/uninstall-ignore-deprecations
uninstall: ignore deprecations when uninstalling.
2016-11-18 13:06:42 +00:00
Mike McQuaid
f4810e4eb1 Merge pull request #1530 from MikeMcQuaid/audit-homebrew-prefix-test-path
audit: check for HOMEBREW_PREFIX test path usage.
2016-11-18 12:37:46 +00:00
Kaito Udagawa
e9815bf2bd install: add tests with custom requirements 2016-11-18 20:47:46 +09:00
Mike McQuaid
39a0fec95d uninstall: ignore deprecations when uninstalling.
Handle `MethodDeprecatedError` because we want people to be able to
uninstall regardless of the content of their formula.
2016-11-18 09:34:58 +00:00
Mike McQuaid
e4fb108079 audit: check for HOMEBREW_PREFIX test path usage.
This is also not allowed.

As seen in https://github.com/Homebrew/homebrew-core/pull/6996.
2016-11-18 09:02:39 +00:00
Mike McQuaid
d9ee2d75c5 Merge pull request #1512 from zmwangx/bump-formula-pr-user-supplied-message
bump-formula-pr: add --message option
2016-11-18 08:30:22 +00:00
Mike McQuaid
5bbc610d2c Merge pull request #1534 from woodruffw/use-core-json
utils/json: Replace OkJson with Ruby's core JSON.
2016-11-18 08:10:28 +00:00
William Woodruff
4278ec38e4
utils/json: Replace OkJson with Ruby's core JSON.
Removes OkJson from vendor/, as Ruby has included its own JSON
parser in corelib since 1.9.x and Homebrew is now guaranteed to be
running on 2.x+.
2016-11-17 23:16:21 -05:00
Josh Hagins
0a7307de64 tests: ignore test files in test/vendor/bundle 2016-11-17 19:21:05 -05:00
Zhiming Wang
00532a3e3a
formula: update test_fixtures path
Fix regression caused by #1364.
2016-11-17 15:54:51 -05:00
Zhiming Wang
67999d75f5
bump-formula-pr: add --message option
For user-supplied PR message.
2016-11-17 15:29:33 -05:00
Mike McQuaid
b7f0edd1fd audit: don't check devel version_scheme/revision.
These are formulae-wide so doesn't make sense to iterate through these
for specs and get weird results.

As seem in https://github.com/Homebrew/homebrew-core/pull/6952.
2016-11-17 17:13:52 +00:00
Mike McQuaid
649c7ab48a Merge pull request #1520 from vladshablinsky/list_follow_aliases
cmd/list: follow aliases
2016-11-17 15:58:25 +00:00
Alyssa Ross
3555206a7f formula: make cache clearing methods, *ahem*, clearer 2016-11-17 14:36:49 +00:00
Alyssa Ross
5baf16f50e Revert "uninstall: skip some flaky tests for now."
This reverts commit 50c964df2ebda125366a94f0e8701eaeb0d98fa7.
2016-11-17 14:26:00 +00:00
Alyssa Ross
8bfc205a87 tab: clear Formula.installed cache when created.
This was causing the flaky tests that #1508 started skipping.

This is the second time that `Formula.installed`'s cache has bitten
me with intermittent test failures, and I'd like it to be the last,
so I've made it so the cache is cleared automatically when a tab is
created. This _should_ mean that the cache is cleared any time it
needs to be, with the exception of when a Keg is created artificially
with no tab. I don't think there's anything I can do to automatically
handle that use-case, though.
2016-11-17 14:26:00 +00:00
Markus Reiter
7457af2b23 Move test files back directly to test/. 2016-11-16 23:52:38 +01:00
Markus Reiter
9dc1f8f3cd Require integration_command_test_case in testing_env. 2016-11-16 23:52:38 +01:00
Markus Reiter
9d82acbf30 Separate Homebrew::TestCase from testing_env. 2016-11-16 23:52:38 +01:00
Markus Reiter
7b9fd538fa Move integration_mocks to test/support/helper. 2016-11-16 23:52:38 +01:00
Markus Reiter
4db1317f38 Move all remaining fixtures to test/support/fixtures. 2016-11-16 23:52:38 +01:00
Markus Reiter
4efdbbde06 Rename fs_leak_log to fs_leak.log and move to tmp. 2016-11-16 23:52:37 +01:00
Markus Reiter
e3be9c068b Update .rubocop_todo.yml. 2016-11-16 23:52:37 +01:00
Markus Reiter
6b6b27126d Reorder and rename test files. 2016-11-16 23:52:37 +01:00
Mike McQuaid
edf042ee97 Merge pull request #1522 from MikeMcQuaid/audit-one-previous-commit
audit: only check previous formula version.
2016-11-16 10:25:11 +00:00
Mike McQuaid
31caa8ef93 audit: only check previous formula version.
For calculating the stable/devel versions this should be sufficient as
it's looking at `origin/master` so for a e.g. unmerged pull request this
will stop complaining about mistakes outside the pull request itself.

This will silence all warnings for historic version mistakes (i.e.
before these audit checks were all enabled) which is normally a bad
thing but as this case would rely on modifying history to complete is a
good one.
2016-11-16 09:03:20 +00:00
Mike McQuaid
27ea94adb8 audit: check that there are any stable revisions.
Fixes the exception if `revision_map[formula.stable.version]` is `nil`.
2016-11-16 08:59:52 +00:00
Uladzislau Shablinski
715caea79b cmd/list: follow aliases
Closes #1514
2016-11-16 02:08:38 +03:00