apainintheneck
3eede57ba2
::FromAPILoader tests for cask
2023-02-16 19:35:34 -08:00
Mike McQuaid
08c6b4556d
Merge pull request #14616 from reitermarkus/audit-cask-version
...
Add audit for versions containing colons or slashes.
2023-02-15 11:59:59 +00:00
Bo Anderson
6e1b9ddb49
test/cask/cask_spec: fix test
2023-02-15 04:59:07 +00:00
Mike McQuaid
237eec8ef8
Overhaul Formula/Cask JSON generation
...
- Use constants for placeholders
- Monkeypatch to set `HOMEBREW_PREFIX` consistently to placeholder
- Use environment variable to set `Dir.home` consistently to placeholder
- Use `appdir` short-circuit to set `Cask#appdir` consistently to placeholder
- Use `Cask.generating_hash!` to enable "generating mode" with these patches
- Fix `Formula#caveats` from JSON
Fixes #14505
Fixes #14595
2023-02-14 14:19:40 +00:00
apainintheneck
39c6f7d6fb
Stop including *flight
block source in cask API
...
Originally we were going to try and load the *flight blocks from the API
but we ended up going with downloading the caskfile for the subset of
casks that need this functionality for consisty's sake.
This reverts the following commits from most recent to oldest:
- ffc74a51fb32b66a4cd8bc41dbd076dd23d9100e
- e5616e94fe42505434c330be35eeafef2739944f
- d1490c3d5c087d00f2bca1787cce331202b195c5
- 7ca5a5d9a71a73f21bbb8555a38048f027bee89b
- 2d5d132713d0701d02d5ff33e9918812d13d2a83
It also changes how *flight blocks are handled in `.to_h`.
Essentially, when *flight blocks exist they are just included
as a hash of the artifact to nil to indicate that they exist.
More information isn't necessary since we don't evaluate
the current source code in the *flight artifacts that
we get from the API.
2023-02-13 21:22:18 -08:00
Markus Reiter
cd18703582
Add audit for versions containing colons or slashes.
2023-02-14 02:08:56 +01:00
Markus Reiter
b821a00bc5
Pass only
and except
to cask audits.
2023-02-08 08:38:32 +01:00
Mike McQuaid
1c1c1623e2
test/cask/cmd/list: add tap_git_head.
2023-02-02 12:19:44 +00:00
Rylan Polster
f38ac3943f
Fix tests
2023-01-28 02:39:23 -06:00
Luca Ongaro
490679da45
Improve test
2023-01-25 00:19:37 +01:00
Luca Ongaro
1fc1c82aed
Fix code style and add tests
2023-01-25 00:08:15 +01:00
Mike McQuaid
f22f3eaa0b
Merge pull request #14400 from dduugg/rspec-cop-fix
...
Resolve RSpec/VerifiedDoubles todos
2023-01-23 13:36:37 +00:00
Douglas Eichelberger
a83623e4cf
Resolve cask/pkg_spec violation
2023-01-22 17:09:55 -08:00
Douglas Eichelberger
585098a9b9
Resolve cask/installer_spec violation
2023-01-22 17:09:55 -08:00
Douglas Eichelberger
357807fbac
Resolve cask/artifact/pkg_spec violation
2023-01-22 17:09:55 -08:00
Alexander Regueiro
b2b7072fbe
Permit multiple uninstall
stanzas in casks (temp)
...
Longer-term solution is described [here](https://github.com/Homebrew/brew/issues/14365#issuecomment-1398214354 ).
2023-01-21 18:45:58 +00:00
Ilya Kulakov
3d16112b14
cask: fix writability check backing up an artifact
2023-01-13 15:30:14 -08:00
Douglas Eichelberger
b4ed7b9924
Add tests
2023-01-11 09:04:09 -08:00
Rylan Polster
7ca5a5d9a7
Simplify require "method_source"
calls
2023-01-02 17:41:36 -05:00
Rylan Polster
2d5d132713
Include *flight
block source in cask API
2023-01-02 14:33:33 -05:00
Mike McQuaid
5994f165f5
Merge pull request #14123 from bevanjkay/cask-wildcard-launchctl
...
cask/artifact/abstract_uninstall: allow wildcard entries for launchctl
2022-12-29 19:26:53 +00:00
Bevan Kay
3bdab156c2
add additional test
2022-12-29 12:54:21 +11:00
Bevan Kay
db9d48a7ec
fix tests
2022-12-28 12:50:16 +11:00
Bevan Kay
01f865f93a
update test
2022-12-19 14:35:31 +11:00
Mike McQuaid
77c0d38c35
brew style --fix
2022-12-13 11:37:06 +00:00
Bevan Kay
e8e6ee30b4
add initial tests
2022-12-13 00:00:43 +11:00
Ian Gregory
a715dec49d
Add --adopt
switch
...
Allows `brew install` & co. to adopt existing cask artifacts that are
identical to those being installed.
Discussion: #14006
2022-10-21 23:28:51 -04:00
Bo Anderson
eac32f0b20
Additional fixes for Ruby 3 compatibility
2022-10-18 01:54:59 +01:00
Sean Molenaar
67c6cae6a0
Merge pull request #13857 from SMillerDev/feature/cask/auto_audit
...
Cask: automatically add cask audits
2022-09-15 16:27:07 +02:00
Sean Molenaar
f049e90e41
audit_spec: style fix
2022-09-15 15:33:25 +02:00
Sean Molenaar
5697ca79b1
audit_spec: limit stanza check
2022-09-15 15:27:43 +02:00
Sean Molenaar
ff54095b8a
Cask: automatically add cask audits
...
This reverts commit 16618374653dc5461dd971e8ed1992188cc3803d.
2022-09-13 11:19:33 +02:00
Mike McQuaid
7349c2b996
brew style --fix
2022-09-13 09:43:09 +01:00
Mike McQuaid
1661837465
Revert "Cask: automatically add cask audits"
2022-09-06 11:46:40 +01:00
Sean Molenaar
86f011cefb
Cask: automatically add cask audits
2022-08-29 11:28:20 +02:00
Rylan Polster
5c7e7eebe4
Condense artifact entries
...
Co-authored-by: Mike McQuaid <mike@mikemcquaid.com>
2022-08-25 10:24:30 -04:00
Rylan Polster
90d22bc7b1
Include dsl key in cask artifact hash
2022-08-25 03:04:48 -04:00
Rylan Polster
fcb30c1ead
Merge pull request #13702 from Rylan12/sha256-arch
...
Add `arm:` and `intel:` arguments to cask `sha256` stanza
2022-08-17 10:34:04 -04:00
Sean Molenaar
cc61a759ed
Merge pull request #13627 from SMillerDev/feature/cask/signing_check
...
cask: add audit for incorrect signing
2022-08-16 10:51:59 +02:00
Rylan Polster
686e02b7ce
Add arm:
and intel:
arguments to cask sha256
stanza
2022-08-16 00:48:24 -04:00
fn ⌃ ⌥
783fcfb97c
Fix tests
2022-08-15 07:52:32 -07:00
Sean Molenaar
e90371f8ab
cask: add audit for incorrect signing
2022-08-11 09:11:29 +02:00
Rylan Polster
19c955d19a
Fix tests
2022-08-09 14:54:33 -04:00
Rylan Polster
76ae20a12f
Re-add on_arch_conditional
DSL
2022-08-09 11:34:52 -04:00
Rylan Polster
dd72f1ac95
Add arch
cask DSL
2022-08-05 17:12:55 -04:00
Rylan Polster
6c35317732
Add and update tests
2022-07-21 16:41:23 +02:00
Rylan Polster
eab3d077bc
Improvements
2022-07-21 15:32:51 +02:00
apainintheneck
ee68f813d8
cask/cmd/list_spec.rb: fix leaky version variable
...
The lazy evaluation in let() was failing to reset MacOS#full_version
to the original_macos_version. This meant that all tests run after
this one automatically had MacOS#version == 12 which caused some
of the tests to fail if you were running a different macOS version.
2022-07-11 15:23:31 -07:00
Mike McQuaid
2d5eab2e1c
brew style --fix
2022-06-30 08:56:21 +01:00
Rylan Polster
ac067eedb2
Create MacOSVersions
module
2022-06-29 11:34:49 -04:00