aboutsummaryrefslogtreecommitdiffstats
path: root/Library
diff options
context:
space:
mode:
authorHannu Hartikainen2014-04-02 00:38:06 +0300
committerMike McQuaid2014-04-02 13:00:46 +0100
commitedba565a1af55442c3d5ccb176f4752291ab59c0 (patch)
treeaa7e03626848ad10ebff5eb23e5d9271085a8737 /Library
parentd1ab2cf3e466c7c95993f020d87011731cc0a97f (diff)
downloadhomebrew-edba565a1af55442c3d5ccb176f4752291ab59c0.tar.bz2
curl: add a test (fetches its own tarball)
Closes #28053. Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
Diffstat (limited to 'Library')
-rw-r--r--Library/Formula/curl.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/Library/Formula/curl.rb b/Library/Formula/curl.rb
index 7521d1367..e109a912e 100644
--- a/Library/Formula/curl.rb
+++ b/Library/Formula/curl.rb
@@ -64,4 +64,12 @@ class Curl < Formula
system "./configure", *args
system "make install"
end
+
+ test do
+ # Fetch the curl tarball and see that the checksum matches.
+ # This requires a network connection, but so does Homebrew in general.
+ filename = (testpath/"test.tar.gz")
+ system "curl", stable.url, "-o", filename
+ filename.verify_checksum stable.checksum
+ end
end