From edba565a1af55442c3d5ccb176f4752291ab59c0 Mon Sep 17 00:00:00 2001 From: Hannu Hartikainen Date: Wed, 2 Apr 2014 00:38:06 +0300 Subject: curl: add a test (fetches its own tarball) Closes #28053. Signed-off-by: Mike McQuaid --- Library/Formula/curl.rb | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'Library/Formula') 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 -- cgit v1.2.3