-
-
Notifications
You must be signed in to change notification settings - Fork 9.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
cask internal json v3: add + update tests
- Loading branch information
1 parent
6cf84ed
commit 72f84ba
Showing
6 changed files
with
192 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
118 changes: 118 additions & 0 deletions
118
Library/Homebrew/test/support/fixtures/internal_tap_json/homebrew-cask.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,118 @@ | ||
{ | ||
"tap_git_head": "b26c1e550a8b7eed2dcd5306ea8f3da3848258b3", | ||
"renames": { | ||
"ankerslicer": "ankermake", | ||
"autodesk-fusion360": "autodesk-fusion", | ||
"betterdummy": "betterdisplay", | ||
"julia-lang": "julia", | ||
"smlnj-lang": "smlnj" | ||
}, | ||
"tap_migrations": { | ||
"azure-cli": "homebrew/core", | ||
"basex": "homebrew/core", | ||
"borgbackup": "homebrew/core", | ||
"chronograf": "homebrew/core", | ||
"consul": "homebrew/core" | ||
}, | ||
"casks": { | ||
"julia": { | ||
"token": "julia", | ||
"name": [ | ||
"Julia" | ||
], | ||
"desc": "Programming language for technical computing", | ||
"homepage": "https://julialang.org/", | ||
"url": "https://julialang-s3.julialang.org/bin/mac/x64/1.10/julia-1.10.2-mac64.dmg", | ||
"version": "1.10.2", | ||
"sha256": "26b822154ae05f2c2b66d2b1538e1df86f1bb39967cbc9380a7f2271f5a677ce", | ||
"artifacts": [ | ||
{ | ||
"app": [ | ||
"Julia-1.10.app" | ||
] | ||
}, | ||
{ | ||
"binary": [ | ||
"$APPDIR/Julia-1.10.app/Contents/Resources/julia/bin/julia" | ||
] | ||
}, | ||
{ | ||
"manpage": [ | ||
"$APPDIR/Julia-1.10.app/Contents/Resources/julia/share/man/man1/julia.1" | ||
] | ||
}, | ||
{ | ||
"zap": [ | ||
{ | ||
"trash": [ | ||
"~/.julia", | ||
"~/Library/Logs/Julia", | ||
"~/Library/Preferences/com.github.Julia.plist", | ||
"~/Library/Preferences/julia.plist", | ||
"~/Library/Saved Application State/com.github.Julia.savedState" | ||
] | ||
} | ||
] | ||
} | ||
], | ||
"ruby_source_path": "Casks/j/julia.rb", | ||
"ruby_source_sha256": "7fbf6c98c0a3b75ca8636c141f38512a899565a58518fc714e5f73c210e24449", | ||
"variations": { | ||
"arm64_sonoma": { | ||
"url": "https://julialang-s3.julialang.org/bin/mac/aarch64/1.10/julia-1.10.2-macaarch64.dmg", | ||
"sha256": "924899e14c1c63624a3872c8c3124a6bf0cb248a7d935b7da01714adb968db6f" | ||
}, | ||
"arm64_ventura": { | ||
"url": "https://julialang-s3.julialang.org/bin/mac/aarch64/1.10/julia-1.10.2-macaarch64.dmg", | ||
"sha256": "924899e14c1c63624a3872c8c3124a6bf0cb248a7d935b7da01714adb968db6f" | ||
}, | ||
"arm64_monterey": { | ||
"url": "https://julialang-s3.julialang.org/bin/mac/aarch64/1.10/julia-1.10.2-macaarch64.dmg", | ||
"sha256": "924899e14c1c63624a3872c8c3124a6bf0cb248a7d935b7da01714adb968db6f" | ||
}, | ||
"arm64_big_sur": { | ||
"url": "https://julialang-s3.julialang.org/bin/mac/aarch64/1.10/julia-1.10.2-macaarch64.dmg", | ||
"sha256": "924899e14c1c63624a3872c8c3124a6bf0cb248a7d935b7da01714adb968db6f" | ||
} | ||
} | ||
}, | ||
"smlnj": { | ||
"token": "smlnj", | ||
"name": [ | ||
"Standard ML of New Jersey" | ||
], | ||
"desc": "Compiler for the Standard ML '97 programming language", | ||
"homepage": "https://www.smlnj.org/", | ||
"url": "http://smlnj.cs.uchicago.edu/dist/working/110.99.4/smlnj-amd64-110.99.4.pkg", | ||
"version": "110.99.4", | ||
"sha256": "2bf858017b8ba43a70b30527290ed9fbbc81d9eaac1abeba62469d95392019a3", | ||
"artifacts": [ | ||
{ | ||
"uninstall": [ | ||
{ | ||
"pkgutil": "org.smlnj.amd64.pkg" | ||
} | ||
] | ||
}, | ||
{ | ||
"pkg": [ | ||
"smlnj-amd64-110.99.4.pkg" | ||
] | ||
}, | ||
{ | ||
"zap": [ | ||
{ | ||
"delete": "/usr/local/smlnj" | ||
} | ||
] | ||
} | ||
], | ||
"ruby_source_path": "Casks/s/smlnj.rb", | ||
"ruby_source_sha256": "d47f46a88248272314a501741460d42a8c731030912a83ef58d3c7fd1e90034d", | ||
"url_specs": { | ||
"verified": "smlnj.cs.uchicago.edu/" | ||
}, | ||
"caveats": "To use smlnj, you may need to add the /usr/local/smlnj/bin directory\nto your PATH environment variable, e.g. (for Bash shell):\n export PATH=/usr/local/smlnj/bin:\"$PATH\"\n" | ||
} | ||
} | ||
} |
29 changes: 29 additions & 0 deletions
29
Library/Homebrew/test/support/fixtures/internal_tap_json/homebrew-cask/Casks/j/julia.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
cask "julia" do | ||
arch arm: "aarch64", intel: "x64" | ||
|
||
version "1.10.2" | ||
sha256 arm: "924899e14c1c63624a3872c8c3124a6bf0cb248a7d935b7da01714adb968db6f", | ||
intel: "26b822154ae05f2c2b66d2b1538e1df86f1bb39967cbc9380a7f2271f5a677ce" | ||
|
||
url "https://julialang-s3.julialang.org/bin/mac/#{arch}/#{version.major_minor}/julia-#{version}-mac#{arch.delete_prefix("x")}.dmg" | ||
name "Julia" | ||
desc "Programming language for technical computing" | ||
homepage "https://julialang.org/" | ||
|
||
livecheck do | ||
url "https://julialang.org/downloads/" | ||
regex(/href=.*?julia[._-]v?(\d+(?:\.\d+)+)[._-]mac#{arch.delete_prefix("x")}\.dmg/i) | ||
end | ||
|
||
app "Julia-#{version.major_minor}.app" | ||
binary "#{appdir}/Julia-#{version.major_minor}.app/Contents/Resources/julia/bin/julia" | ||
manpage "#{appdir}/Julia-#{version.major_minor}.app/Contents/Resources/julia/share/man/man1/julia.1" | ||
|
||
zap trash: [ | ||
"~/.julia", | ||
"~/Library/Logs/Julia", | ||
"~/Library/Preferences/com.github.Julia.plist", | ||
"~/Library/Preferences/julia.plist", | ||
"~/Library/Saved Application State/com.github.Julia.savedState", | ||
] | ||
end |
25 changes: 25 additions & 0 deletions
25
Library/Homebrew/test/support/fixtures/internal_tap_json/homebrew-cask/Casks/s/smlnj.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
cask "smlnj" do | ||
version "110.99.4" | ||
sha256 "2bf858017b8ba43a70b30527290ed9fbbc81d9eaac1abeba62469d95392019a3" | ||
|
||
url "http://smlnj.cs.uchicago.edu/dist/working/#{version}/smlnj-amd64-#{version}.pkg", | ||
verified: "smlnj.cs.uchicago.edu/" | ||
name "Standard ML of New Jersey" | ||
desc "Compiler for the Standard ML '97 programming language" | ||
homepage "https://www.smlnj.org/" | ||
|
||
livecheck do | ||
url :homepage | ||
regex(%r{href=.*?/smlnj-amd64-(\d+(?:\.\d+)*)\.pkg}i) | ||
end | ||
|
||
pkg "smlnj-amd64-#{version}.pkg" | ||
|
||
uninstall pkgutil: "org.smlnj.amd64.pkg" | ||
|
||
zap delete: "/usr/local/smlnj" | ||
|
||
caveats do | ||
path_environment_variable "/usr/local/smlnj/bin" | ||
end | ||
end |
7 changes: 7 additions & 0 deletions
7
Library/Homebrew/test/support/fixtures/internal_tap_json/homebrew-cask/cask_renames.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"ankerslicer": "ankermake", | ||
"autodesk-fusion360": "autodesk-fusion", | ||
"betterdummy": "betterdisplay", | ||
"julia-lang": "julia", | ||
"smlnj-lang": "smlnj" | ||
} |
7 changes: 7 additions & 0 deletions
7
Library/Homebrew/test/support/fixtures/internal_tap_json/homebrew-cask/tap_migrations.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"azure-cli": "homebrew/core", | ||
"basex": "homebrew/core", | ||
"borgbackup": "homebrew/core", | ||
"chronograf": "homebrew/core", | ||
"consul": "homebrew/core" | ||
} |